Não pode escolher mais do que 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

há 3 anos
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. # Global Styles for JSS
  2. If you want to write regular globally scoped CSS with JSS, this plugin is for you. Don't use it if you can avoid it.
  3. [![Gitter](https://badges.gitter.im/JoinChat.svg)](https://gitter.im/cssinjs/lobby)
  4. ## Top level global declarations block
  5. ```javascript
  6. const styles = {
  7. '@global': {
  8. body: {
  9. color: 'green'
  10. },
  11. a: {
  12. textDecoration: 'underline'
  13. }
  14. }
  15. }
  16. ```
  17. ## Top level global prefix
  18. ```javascript
  19. const styles = {
  20. '@global body': {
  21. color: 'green'
  22. }
  23. }
  24. ```
  25. ## Nested global declarations block
  26. ```javascript
  27. const styles = {
  28. button: {
  29. float: 'left',
  30. '@global': {
  31. span: {color: 'red'}
  32. }
  33. }
  34. }
  35. ```
  36. ## Nested global prefix
  37. ```javascript
  38. const styles = {
  39. button: {
  40. float: 'left',
  41. '@global span': {color: 'red'}
  42. }
  43. }
  44. ```
  45. ## Issues
  46. File a bug against [cssinjs/jss prefixed with \[jss-global\]](https://github.com/cssinjs/jss/issues/new?title=[jss-global]%20).
  47. ## Run tests
  48. ```bash
  49. npm i
  50. npm run test
  51. ```
  52. ## License
  53. MIT