origam 2.18.17 → 2.18.19

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.
Files changed (44) hide show
  1. package/CHANGELOG.md +981 -0
  2. package/dist/src/assets/css/main.css +1 -1
  3. package/dist/src/assets/css/tokens/dark.css +212 -6
  4. package/dist/src/assets/css/tokens/light.css +106 -3
  5. package/dist/src/assets/scss/tokens/_dark.scss +212 -6
  6. package/dist/src/assets/scss/tokens/_light.scss +106 -3
  7. package/dist/src/components/Audio/OrigamAudio.vue +66 -2
  8. package/dist/src/components/Chip/OrigamChip.vue +34 -0
  9. package/dist/src/components/Field/OrigamField.vue +76 -3
  10. package/dist/src/components/List/OrigamList.vue +90 -3
  11. package/dist/src/components/Main/OrigamMain.vue +2 -2
  12. package/dist/src/components/Media/OrigamMediaScrubber.vue +11 -1
  13. package/dist/src/components/Pagination/OrigamPagination.vue +64 -2
  14. package/dist/src/components/SliderField/OrigamSliderField.vue +138 -3
  15. package/dist/src/components/SliderField/OrigamSliderFieldTrack.vue +12 -1
  16. package/dist/src/components/Snackbar/OrigamSnackbar.vue +2 -2
  17. package/dist/src/components/Switch/OrigamSwitch.vue +32 -0
  18. package/dist/src/components/TextField/OrigamTextField.vue +3 -1
  19. package/dist/src/components/Toolbar/OrigamToolbar.vue +58 -0
  20. package/dist/src/components/Video/OrigamVideo.vue +11 -1
  21. package/dist/src/composables/Commons/layout.composable.cjs +2 -2
  22. package/dist/src/composables/Commons/layout.composable.d.ts +16 -2
  23. package/dist/src/composables/Commons/layout.composable.js +1 -1
  24. package/dist/src/composables/Commons/theme-props-resolver.composable.cjs +44 -9
  25. package/dist/src/composables/Commons/theme-props-resolver.composable.d.ts +33 -1
  26. package/dist/src/composables/Commons/theme-props-resolver.composable.js +42 -10
  27. package/dist/src/consts/Commons/variant-preset.const.cjs +8 -0
  28. package/dist/src/consts/Commons/variant-preset.const.d.ts +60 -0
  29. package/dist/src/consts/Commons/variant-preset.const.js +2 -0
  30. package/dist/src/consts/index.cjs +11 -0
  31. package/dist/src/consts/index.d.ts +1 -0
  32. package/dist/src/consts/index.js +1 -0
  33. package/dist/src/interfaces/Commons/theme.interface.d.ts +33 -0
  34. package/dist/src/interfaces/Masonry/masonry.interface.d.ts +2 -2
  35. package/dist/src/origam.cjs +2 -1
  36. package/dist/src/origam.js +8 -2
  37. package/dist/src/types/Commons/variant-preset.type.cjs +1 -0
  38. package/dist/src/types/Commons/variant-preset.type.d.ts +73 -0
  39. package/dist/src/types/Commons/variant-preset.type.js +0 -0
  40. package/dist/src/types/index.cjs +11 -0
  41. package/dist/src/types/index.d.ts +1 -0
  42. package/dist/src/types/index.js +1 -0
  43. package/dist/src/types/tokens.type.d.ts +1 -1
  44. package/package.json +1 -1
@@ -0,0 +1,73 @@
1
+ /*********************************************************
2
+ * TVariantPresets
3
+ *
4
+ * @description
5
+ * ADR-005 (D1) — un `variant` EST une preconfiguration de props nommee,
6
+ * pas une couche CSS : `Record<valeur du variant, Partial<props>>`.
7
+ *
8
+ * @description
9
+ * C'est le type d'AUTORAT, celui qu'une table
10
+ * `consts/{Composant}/{composant}-variant.const.ts` annote pour que le
11
+ * compilateur refuse une valeur de variant inconnue ou un nom de prop que
12
+ * le composant ne declare pas :
13
+ *
14
+ * export const KBD_VARIANT_PRESETS: TVariantPresets<TKbdVariant, IKbdProps> = {
15
+ * outlined: { bgColor: '...', border: 1 },
16
+ * filled: { bgColor: '...' },
17
+ * tonal: { bgColor: '...', border: 0 }
18
+ * }
19
+ *
20
+ * @description
21
+ * ⛔ AUCUN SCSS N'ACCOMPAGNE UNE TABLE DE PRESETS. La classe
22
+ * `{nom}--variant-{valeur}` que `useVariant()` emet continue d'exister,
23
+ * mais le DS ne lui attache plus aucune regle : elle appartient au
24
+ * CONSOMMATEUR, comme crochet d'override. Le garde `no-variant-css` tient
25
+ * cette moitie du contrat.
26
+ *
27
+ * @description
28
+ * ⛔ LES VALEURS NE SE RE-EXPRIMENT PAS EN ECHELON SEMANTIQUE. Mesure
29
+ * (2026-09-30) : les 8 themes de marque
30
+ * (`packages/marketing/src/themes/*.theme.ts`) habillent leurs boutons A
31
+ * TRAVERS les tokens de composant que la regle de variant lisait —
32
+ * `cartoon` pose `--origam-btn---box-shadow-elevated: 4px 4px 0 #171717`,
33
+ * `glass` une ombre de verre a quatre couches. Un preset ecrit
34
+ * `elevation: 'md'` emet `var(--origam-shadow---md)` et jette donc
35
+ * silencieusement l'ombre de la marque sur les 8 identites x 2 modes.
36
+ * @description
37
+ * Un preset porte la MEME chaine `var(--origam-{cmp}---{...}, <repli>)`
38
+ * que portait la regle, jamais sa traduction en echelon : le canal
39
+ * d'override des themes survit, et le rendu est identique par
40
+ * construction. `TElevation` documente le `box-shadow` libre (dont
41
+ * `var()`, multi-couches, `inset`) rendu verbatim, et `isCssColor`
42
+ * accepte `var(--…)` comme `color-mix(…)` en les routant vers le canal
43
+ * de style « valeur custom ».
44
+ ********************************************************/
45
+ export type TVariantPresets<V extends string, P> = Record<V, Partial<P>>;
46
+ /*********************************************************
47
+ * TVariantPresetTable
48
+ *
49
+ * @description
50
+ * La meme table, vue par le RESOLVEUR : valeur du variant -> sac de props.
51
+ *
52
+ * @description
53
+ * Type efface a dessein. Le resolveur est generique sur les 217
54
+ * composants et ne peut etre parametre par aucun `IXxxProps` en
55
+ * particulier ; c'est la table d'autorat qui porte le typage fort, au
56
+ * point d'ecriture, ou il sert reellement a quelque chose.
57
+ ********************************************************/
58
+ export type TVariantPresetTable = Record<string, Record<string, unknown>>;
59
+ /*********************************************************
60
+ * TVariantPresetRegistry
61
+ *
62
+ * @description
63
+ * Nom kebab du composant (`'origam-btn'`) -> sa table de presets.
64
+ *
65
+ * @description
66
+ * Meme forme que ce qu'un theme peut declarer sous `IOrigamTheme.variants`
67
+ * (ADR-005 D4). C'est une exigence, pas une coincidence : la directive
68
+ * d'implementation de l'ADR veut qu'un preset soit « une config par defaut
69
+ * comme avec le theme, la meme logique ». Si les deux formes divergeaient,
70
+ * la fusion du lot 1 et les variants definis par le consommateur
71
+ * demanderaient deux chemins de resolution au lieu d'un.
72
+ ********************************************************/
73
+ export type TVariantPresetRegistry = Record<string, TVariantPresetTable>;
File without changes
@@ -619,6 +619,17 @@ Object.keys(_variant).forEach(function (key) {
619
619
  }
620
620
  });
621
621
  });
622
+ var _variantPreset = require("./Commons/variant-preset.type.cjs");
623
+ Object.keys(_variantPreset).forEach(function (key) {
624
+ if (key === "default" || key === "__esModule") return;
625
+ if (key in exports && exports[key] === _variantPreset[key]) return;
626
+ Object.defineProperty(exports, key, {
627
+ enumerable: true,
628
+ get: function () {
629
+ return _variantPreset[key];
630
+ }
631
+ });
632
+ });
622
633
  var _direction = require("./Commons/direction.type.cjs");
623
634
  Object.keys(_direction).forEach(function (key) {
624
635
  if (key === "default" || key === "__esModule") return;
@@ -54,6 +54,7 @@ export * from './Commons/rounded.type';
54
54
  export * from './Commons/dimension.type';
55
55
  export * from './Commons/elevation.type';
56
56
  export * from './Commons/variant.type';
57
+ export * from './Commons/variant-preset.type';
57
58
  export * from './Commons/direction.type';
58
59
  export * from './Commons/display.type';
59
60
  export * from './Commons/event.type';
@@ -54,6 +54,7 @@ export * from "./Commons/rounded.type.js";
54
54
  export * from "./Commons/dimension.type.js";
55
55
  export * from "./Commons/elevation.type.js";
56
56
  export * from "./Commons/variant.type.js";
57
+ export * from "./Commons/variant-preset.type.js";
57
58
  export * from "./Commons/direction.type.js";
58
59
  export * from "./Commons/display.type.js";
59
60
  export * from "./Commons/event.type.js";