quotes.css 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192
  1. @charset "UTF-8";
  2. /* @charset must always have double quotes: https://www.w3.org/TR/css-syntax-3/#determine-the-fallback-encoding */
  3. /* Also, it has to be the very first thing in the file, but here are some more tests anyway: */
  4. @charset 'UTF-8'; /* Single quotes are invalid here. Keep them since we don't know what the user is doing. */
  5. @supports (content: one "two" three 'four') {
  6. a[href="foo" y],
  7. abbr[title^='It\'s a trap!'],
  8. img[src=""] {
  9. /* Simple strings. */
  10. content: "abc";
  11. content: 'abc';
  12. /* Escape. */
  13. content: '\A';
  14. /* Emoji. */
  15. content: '🐶';
  16. /* Empty string. */
  17. content: "";
  18. content: '';
  19. /* Single double quote. */
  20. content: "\"";
  21. content: '"';
  22. /* Single single quote. */
  23. content: "'";
  24. content: '\'';
  25. /* One of each. */
  26. content: "\"'";
  27. content: '"\'';
  28. /* One of each with unnecessary escapes. */
  29. content: "\"\'";
  30. content: '\"\'';
  31. /* More double quotes than single quotes. */
  32. content: "\"'\"";
  33. content: '"\'"';
  34. /* More single quotes than double quotes. */
  35. content: "\"''";
  36. content: '"\'\'';
  37. /* Two of each. */
  38. content: "\"\"''";
  39. content: '""\'\'';
  40. /* Single backslash. */
  41. content: '\\';
  42. content: "\\";
  43. /* Backslases. */
  44. content: "\"\\\"\\\\\" '\'\\'\\\'\\\\'";
  45. content: '\'\\\'\\\\\' "\"\\"\\\"\\\\"';
  46. /* Somewhat more real-word example. */
  47. content: "He's sayin': \"How's it goin'?\" Don't ask me why.";
  48. content: 'He\'s sayin\': "How\'s it goin\'?" Don\'t ask me why.';
  49. /* Somewhat more real-word example 2. */
  50. content: "var backslash = \"\\\", doubleQuote = '\"';";
  51. content: 'var backslash = "\\", doubleQuote = \'"\';';
  52. /* Leave all "escapes" alone. */
  53. content: "\Abc4 foo \n" /* "comment" */ "\end";
  54. content: '\Abc4 foo \n' /* 'comment' */ '\end';
  55. }
  56. }
  57. @import "file.css";
  58. @import 'file.css';
  59. @import url("foo.css");
  60. @import url('foo.css');
  61. @import "foo.css" screen and (orientation: landscape);
  62. @import 'foo.css' screen and (orientation: landscape);
  63. @foo "one";
  64. @foo 'one';
  65. @foo "one" two 'three';
  66. @foo ("one");
  67. @foo ('one');
  68. @foo ("one" two 'three');
  69. one "two" three {}
  70. one 'two' three {}