@med-o/design-tokens 0.1.0 → 0.3.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.
@@ -4,6 +4,7 @@
4
4
  *
5
5
  * Theme: follows the system setting. Force a theme with data-theme="light" | "dark"
6
6
  * on <html> or on any element (the theme then applies to that subtree).
7
+ * Contrast: “Increase contrast” in the system (prefers-contrast: more) strengthens secondary text and borders.
7
8
  */
8
9
 
9
10
  :root {
@@ -713,6 +714,28 @@
713
714
  }
714
715
  }
715
716
 
717
+ /* Higher contrast: the system setting “Increase contrast” (prefers-contrast: more). */
718
+ @media (prefers-contrast: more) {
719
+ :root,
720
+ [data-theme] {
721
+ --medo-color-border-default: var(--medo-color-border-strong);
722
+ }
723
+ :root,
724
+ [data-theme="light"] {
725
+ --medo-color-text-secondary: var(--medo-color-neutral-700);
726
+ }
727
+ [data-theme="dark"] {
728
+ --medo-color-text-secondary: var(--medo-color-neutral-300);
729
+ }
730
+ @media (prefers-color-scheme: dark) {
731
+ /* Same specificity as the system dark block above, so both overrides are repeated here. */
732
+ :root:not([data-theme="light"]) {
733
+ --medo-color-border-default: var(--medo-color-border-strong);
734
+ --medo-color-text-secondary: var(--medo-color-neutral-300);
735
+ }
736
+ }
737
+ }
738
+
716
739
  /* Layout: modes Mobile (default), Tablet (≥ 640px), Desktop (≥ 1024px) */
717
740
  @media (min-width: 640px) {
718
741
  :root {
@@ -180,8 +180,7 @@
180
180
  font-size: var(--medo-font-size-xs);
181
181
  font-weight: var(--medo-font-weight-semibold);
182
182
  line-height: 1.3333;
183
- letter-spacing: var(--medo-font-tracking-wide);
184
- text-transform: uppercase;
183
+ letter-spacing: var(--medo-font-tracking-normal);
185
184
  }
186
185
 
187
186
  /* code/md */
@@ -4168,7 +4168,7 @@
4168
4168
  "type": "duration",
4169
4169
  "cssVar": "--medo-motion-duration-fast",
4170
4170
  "value": "0.1s",
4171
- "description": "100 ms: feedback – hover, pressed, focus, color and opacity. Pressed starts at once and fades out (iOS highlight)."
4171
+ "description": "100 ms: feedback – hover, pressed, focus, color and opacity. Pressed starts at once and fades out, so a tap feels immediate."
4172
4172
  },
4173
4173
  {
4174
4174
  "name": "motion/duration/normal",
@@ -4228,7 +4228,7 @@
4228
4228
  "type": "cubicBezier",
4229
4229
  "cssVar": "--medo-motion-easing-standard",
4230
4230
  "value": "cubic-bezier(0.32, 0.72, 0, 1)",
4231
- "description": "cubic-bezier(0.32, 0.72, 0, 1): the iOS ease-out – state changes and movement within the view where no spring is used."
4231
+ "description": "cubic-bezier(0.32, 0.72, 0, 1): a strong ease-out (fast start, long soft landing) – state changes and movement within the view where no spring is used."
4232
4232
  },
4233
4233
  {
4234
4234
  "name": "motion/easing/enter",
@@ -231,7 +231,7 @@
231
231
  --text-overline: var(--medo-font-size-xs);
232
232
  --text-overline--line-height: 1.3333;
233
233
  --text-overline--font-weight: var(--medo-font-weight-semibold);
234
- --text-overline--letter-spacing: var(--medo-font-tracking-wide);
234
+ --text-overline--letter-spacing: var(--medo-font-tracking-normal);
235
235
  --text-code-md: var(--medo-font-size-sm);
236
236
  --text-code-md--line-height: 1.4286;
237
237
  --text-code-md--font-weight: var(--medo-font-weight-regular);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@med-o/design-tokens",
3
- "version": "0.1.0",
3
+ "version": "0.3.0",
4
4
  "description": "Design tokens of the med.o Design System (DTCG source, CSS variables, Tailwind v4 theme, JS).",
5
5
  "type": "module",
6
6
  "license": "MIT",
package/src/motion.json CHANGED
@@ -7,7 +7,7 @@
7
7
  "value": 100,
8
8
  "unit": "ms"
9
9
  },
10
- "$description": "100 ms: feedback – hover, pressed, focus, color and opacity. Pressed starts at once and fades out (iOS highlight)."
10
+ "$description": "100 ms: feedback – hover, pressed, focus, color and opacity. Pressed starts at once and fades out, so a tap feels immediate."
11
11
  },
12
12
  "normal": {
13
13
  "$type": "duration",
@@ -51,7 +51,7 @@
51
51
  0,
52
52
  1
53
53
  ],
54
- "$description": "cubic-bezier(0.32, 0.72, 0, 1): the iOS ease-out – state changes and movement within the view where no spring is used."
54
+ "$description": "cubic-bezier(0.32, 0.72, 0, 1): a strong ease-out (fast start, long soft landing) – state changes and movement within the view where no spring is used."
55
55
  },
56
56
  "enter": {
57
57
  "$type": "cubicBezier",
@@ -420,12 +420,7 @@
420
420
  "fontSize": "{font.size.xs}",
421
421
  "fontWeight": "{font.weight.semibold}",
422
422
  "lineHeight": 1.3333,
423
- "letterSpacing": "{font.tracking.wide}"
424
- },
425
- "$extensions": {
426
- "com.medo": {
427
- "textTransform": "uppercase"
428
- }
423
+ "letterSpacing": "{font.tracking.normal}"
429
424
  }
430
425
  },
431
426
  "code": {