@utrecht/document-css 1.0.0 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md ADDED
@@ -0,0 +1,19 @@
1
+ # @utrecht/document-css
2
+
3
+ ## 1.2.0
4
+
5
+ ### Minor Changes
6
+
7
+ - a42a56a: Added metadata for document tokens.
8
+
9
+ ## 1.1.0
10
+
11
+ ### Minor Changes
12
+
13
+ - 62f1157: Add SCSS files to `src/` directory of CSS component packages.
14
+
15
+ ## 1.0.0
16
+
17
+ ### Major Changes
18
+
19
+ - 856d996: Switch from alpha releases to semantic versioning.
package/_lang.md ADDED
@@ -0,0 +1,7 @@
1
+ <!-- @license CC0-1.0 -->
2
+
3
+ <!-- markdownlint-disable first-line-h1 -->
4
+
5
+ Maak duidelijk welke taal het document is ([WCAG eis 3.1.1](https://www.w3.org/TR/WCAG21/#language-of-page)) met het `lang` attribuut.
6
+
7
+ Het is gebruikelijk om de tweeletterige ISO-639-1 code te gebruiken als die bestaat, anders de drieletterige ISO-639-3 code.
package/dist/index.css ADDED
@@ -0,0 +1,30 @@
1
+ /**
2
+ * @license EUPL-1.2
3
+ * Copyright (c) 2021 Robbert Broersma
4
+ */
5
+ /**
6
+ * @license EUPL-1.2
7
+ * Copyright (c) 2021 Robbert Broersma
8
+ */
9
+ .utrecht-document {
10
+ /* reset `font-smoothing: antialiasing`, prefer automatic (`subpixel-antialiasing`) behavior for high-dpi screens */
11
+ -webkit-font-smoothing: auto !important;
12
+ -moz-osx-font-smoothing: auto !important;
13
+ color: var(--utrecht-document-color, inherit);
14
+ font-family: var(--utrecht-document-font-family, inherit);
15
+ font-size: var(--utrecht-document-font-size, inherit);
16
+ font-weight: var(--utrecht-document-font-weight, inherit);
17
+ line-height: var(--utrecht-document-line-height, inherit);
18
+ text-rendering: optimizeLegibility;
19
+ -moz-text-size-adjust: none;
20
+ -webkit-text-size-adjust: none;
21
+ text-size-adjust: none;
22
+ }
23
+ .utrecht-document :lang(ar) {
24
+ /* `letter-spacing` design tokens break Arabic text rendering, avoid that */
25
+ letter-spacing: 0 !important;
26
+ }
27
+
28
+ .utrecht-document--surface {
29
+ background-color: var(--utrecht-document-background-color, inherit);
30
+ }
package/dist/index.js ADDED
@@ -0,0 +1 @@
1
+ var undefined$1 = undefined;export{undefined$1 as default};
package/package.json CHANGED
@@ -1,18 +1,32 @@
1
1
  {
2
- "version": "1.0.0",
2
+ "version": "1.2.0",
3
3
  "author": "Community for NL Design System",
4
4
  "description": "Document component for the Municipality of Utrecht based on the NL Design System architecture",
5
5
  "license": "EUPL-1.2",
6
6
  "name": "@utrecht/document-css",
7
7
  "files": [
8
- "dist/"
8
+ "dist/",
9
+ "docs/",
10
+ "src/",
11
+ "*.md"
9
12
  ],
10
- "devDependencies": {},
13
+ "main": "dist/index.css",
14
+ "devDependencies": {
15
+ "rollup": "4.18.0"
16
+ },
11
17
  "keywords": [
12
18
  "nl-design-system"
13
19
  ],
14
20
  "publishConfig": {
15
21
  "access": "public"
16
22
  },
17
- "scripts": {}
23
+ "repository": {
24
+ "type": "git+ssh",
25
+ "url": "git@github.com:nl-design-system/utrecht.git",
26
+ "directory": "components/document"
27
+ },
28
+ "scripts": {
29
+ "build": "rollup -c ../rollup.config.mjs",
30
+ "clean": "rimraf dist"
31
+ }
18
32
  }
@@ -0,0 +1,33 @@
1
+ /**
2
+ * @license EUPL-1.2
3
+ * Copyright (c) 2021 Robbert Broersma
4
+ */
5
+
6
+ @mixin reset-font-smoothing {
7
+ /* reset `font-smoothing: antialiasing`, prefer automatic (`subpixel-antialiasing`) behavior for high-dpi screens */
8
+ -webkit-font-smoothing: auto !important;
9
+ -moz-osx-font-smoothing: auto !important;
10
+ }
11
+
12
+ @mixin utrecht-document {
13
+ @include reset-font-smoothing;
14
+
15
+ color: var(--utrecht-document-color, inherit);
16
+ font-family: var(--utrecht-document-font-family, inherit);
17
+ font-size: var(--utrecht-document-font-size, inherit);
18
+ font-weight: var(--utrecht-document-font-weight, inherit);
19
+ line-height: var(--utrecht-document-line-height, inherit);
20
+ text-rendering: optimizeLegibility;
21
+ -moz-text-size-adjust: none;
22
+ -webkit-text-size-adjust: none;
23
+ text-size-adjust: none;
24
+
25
+ :lang(ar) {
26
+ /* `letter-spacing` design tokens break Arabic text rendering, avoid that */
27
+ letter-spacing: 0 !important;
28
+ }
29
+ }
30
+
31
+ @mixin utrecht-document--surface {
32
+ background-color: var(--utrecht-document-background-color, inherit);
33
+ }
@@ -0,0 +1,13 @@
1
+ /**
2
+ * @license EUPL-1.2
3
+ * Copyright (c) 2021 Robbert Broersma
4
+ */
5
+
6
+ @import "../mixin";
7
+
8
+ @mixin utrecht-html-body {
9
+ body {
10
+ @include utrecht-document;
11
+ @include utrecht-document--surface;
12
+ }
13
+ }
@@ -0,0 +1,8 @@
1
+ /**
2
+ * @license EUPL-1.2
3
+ * Copyright (c) 2021 Robbert Broersma
4
+ */
5
+
6
+ @import "./mixin";
7
+
8
+ @include utrecht-html-body;
package/src/index.scss ADDED
@@ -0,0 +1,14 @@
1
+ /**
2
+ * @license EUPL-1.2
3
+ * Copyright (c) 2021 Robbert Broersma
4
+ */
5
+
6
+ @import "./mixin";
7
+
8
+ .utrecht-document {
9
+ @include utrecht-document;
10
+ }
11
+
12
+ .utrecht-document--surface {
13
+ @include utrecht-document--surface;
14
+ }
@@ -0,0 +1,66 @@
1
+ {
2
+ "utrecht": {
3
+ "document": {
4
+ "background-color": {
5
+ "$extensions": {
6
+ "nl.nldesignsystem.css.property": {
7
+ "syntax": "<color>",
8
+ "inherits": true
9
+ },
10
+ "nl.nldesignsystem.figma.supports-token": true
11
+ },
12
+ "type": "color"
13
+ },
14
+ "color": {
15
+ "$extensions": {
16
+ "nl.nldesignsystem.css.property": {
17
+ "syntax": "<color>",
18
+ "inherits": true
19
+ },
20
+ "nl.nldesignsystem.figma.supports-token": true
21
+ },
22
+ "type": "color"
23
+ },
24
+ "font-family": {
25
+ "$extensions": {
26
+ "nl.nldesignsystem.css.property": {
27
+ "syntax": "*",
28
+ "inherits": true
29
+ },
30
+ "nl.nldesignsystem.figma.supports-token": true
31
+ },
32
+ "type": "fontFamilies"
33
+ },
34
+ "font-size": {
35
+ "$extensions": {
36
+ "nl.nldesignsystem.css.property": {
37
+ "syntax": "<length>",
38
+ "inherits": true
39
+ },
40
+ "nl.nldesignsystem.figma.supports-token": true
41
+ },
42
+ "type": "fontSizes"
43
+ },
44
+ "font-weight": {
45
+ "$extensions": {
46
+ "nl.nldesignsystem.css.property": {
47
+ "syntax": "<number>",
48
+ "inherits": true
49
+ },
50
+ "nl.nldesignsystem.figma.supports-token": true
51
+ },
52
+ "type": "fontWeights"
53
+ },
54
+ "line-height": {
55
+ "$extensions": {
56
+ "nl.nldesignsystem.css.property": {
57
+ "syntax": ["<length>", "<number>"],
58
+ "inherits": true
59
+ },
60
+ "nl.nldesignsystem.figma.supports-token": true
61
+ },
62
+ "type": "lineHeights"
63
+ }
64
+ }
65
+ }
66
+ }