@flipova/foundation 1.11.0 → 1.12.1
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 +13 -0
- package/README.md +20 -94
- package/dist/chunk-4KNPSB67.js +423 -0
- package/dist/chunk-4KNPSB67.js.map +1 -0
- package/dist/chunk-4NPMHFKO.mjs +6609 -0
- package/dist/chunk-4NPMHFKO.mjs.map +1 -0
- package/dist/chunk-5N5HC4ZA.mjs +3 -0
- package/dist/{chunk-HS2UOQU4.mjs.map → chunk-5N5HC4ZA.mjs.map} +1 -1
- package/dist/chunk-DJP3T7OD.mjs +413 -0
- package/dist/chunk-DJP3T7OD.mjs.map +1 -0
- package/dist/chunk-DNV5UBNF.mjs +3 -0
- package/dist/chunk-DNV5UBNF.mjs.map +1 -0
- package/dist/chunk-ETR75HWU.mjs +422 -0
- package/dist/chunk-ETR75HWU.mjs.map +1 -0
- package/dist/chunk-IJTI6EX4.js +4 -0
- package/dist/{chunk-2VLBOYBU.js.map → chunk-IJTI6EX4.js.map} +1 -1
- package/dist/chunk-KGMGD6GU.js +7024 -0
- package/dist/chunk-KGMGD6GU.js.map +1 -0
- package/dist/{chunk-D4QJYQOK.js → chunk-KOKOIY5E.js} +49 -44
- package/dist/chunk-KOKOIY5E.js.map +1 -0
- package/dist/{chunk-YTD4AWV2.mjs → chunk-MLFQD3PV.mjs} +42 -37
- package/dist/chunk-MLFQD3PV.mjs.map +1 -0
- package/dist/chunk-O7UP2OZR.js +6705 -0
- package/dist/chunk-O7UP2OZR.js.map +1 -0
- package/dist/chunk-OXKOGLXE.js +4 -0
- package/dist/chunk-OXKOGLXE.js.map +1 -0
- package/dist/chunk-RMLLGNWR.js +428 -0
- package/dist/chunk-RMLLGNWR.js.map +1 -0
- package/dist/chunk-XTYE5PNQ.mjs +6900 -0
- package/dist/chunk-XTYE5PNQ.mjs.map +1 -0
- package/dist/config/index.d.mts +65 -70
- package/dist/config/index.d.ts +65 -70
- package/dist/config/index.js +6 -6
- package/dist/config/index.mjs +1 -1
- package/dist/{index-D4qJw_Et.d.mts → index-CpBqkIpd.d.mts} +25 -2
- package/dist/{index-D4qJw_Et.d.ts → index-CpBqkIpd.d.ts} +25 -2
- package/dist/index.d.mts +7 -5
- package/dist/index.d.ts +7 -5
- package/dist/index.js +499 -298
- package/dist/index.mjs +5 -4
- package/dist/registry/index.d.mts +9693 -0
- package/dist/registry/index.d.ts +9693 -0
- package/dist/registry/index.js +388 -0
- package/dist/registry/index.mjs +3 -0
- package/dist/theme/index.d.mts +46 -49
- package/dist/theme/index.d.ts +46 -49
- package/dist/theme/index.js +7 -39
- package/dist/theme/index.mjs +1 -1
- package/dist/tokens/index.d.mts +265 -130
- package/dist/tokens/index.d.ts +265 -130
- package/dist/tokens/index.js +15 -31
- package/dist/tokens/index.mjs +1 -1
- package/dist/types/index.d.mts +200 -0
- package/dist/types/index.d.ts +200 -0
- package/dist/types/index.js +4 -0
- package/dist/types/index.js.map +1 -0
- package/dist/types/index.mjs +3 -0
- package/dist/types/index.mjs.map +1 -0
- package/dist/ui/index.d.mts +2981 -0
- package/dist/ui/index.d.ts +2981 -0
- package/dist/ui/index.js +729 -0
- package/dist/ui/index.js.map +1 -0
- package/dist/ui/index.mjs +4 -0
- package/dist/ui/index.mjs.map +1 -0
- package/dist/web/index.js +30935 -6072
- package/dist/web/index.js.map +1 -1
- package/dist/web/index.mjs +30747 -6006
- package/dist/web/index.mjs.map +1 -1
- package/package.json +66 -32
- package/dist/chunk-2VLBOYBU.js +0 -4
- package/dist/chunk-32VWREEH.mjs +0 -8256
- package/dist/chunk-32VWREEH.mjs.map +0 -1
- package/dist/chunk-3RJREGCN.js +0 -8407
- package/dist/chunk-3RJREGCN.js.map +0 -1
- package/dist/chunk-D4QJYQOK.js.map +0 -1
- package/dist/chunk-HS2UOQU4.mjs +0 -3
- package/dist/chunk-IKVONTJC.mjs +0 -397
- package/dist/chunk-IKVONTJC.mjs.map +0 -1
- package/dist/chunk-RRV2Q4SS.mjs +0 -655
- package/dist/chunk-RRV2Q4SS.mjs.map +0 -1
- package/dist/chunk-RUZBEFDO.js +0 -669
- package/dist/chunk-RUZBEFDO.js.map +0 -1
- package/dist/chunk-UBZMVSIN.js +0 -412
- package/dist/chunk-UBZMVSIN.js.map +0 -1
- package/dist/chunk-YTD4AWV2.mjs.map +0 -1
- package/dist/layout/index.d.mts +0 -2529
- package/dist/layout/index.d.ts +0 -2529
- package/dist/layout/index.js +0 -512
- package/dist/layout/index.mjs +0 -3
- package/dist/spacing-CXUulLF9.d.mts +0 -128
- package/dist/spacing-CXUulLF9.d.ts +0 -128
- package/dist/sso/index.js +0 -379
- package/dist/sso/index.js.map +0 -1
- package/dist/sso/index.mjs +0 -374
- package/dist/sso/index.mjs.map +0 -1
- package/dist/studio-v2/cli/index.js +0 -96
- package/studio-v2/apps/web/CHANGELOG.md +0 -7
- package/studio-v2/apps/web/LICENSE +0 -21
- package/studio-v2/apps/web/README.md +0 -56
- package/studio-v2/apps/web/dist/+not-found.html +0 -793
- package/studio-v2/apps/web/dist/_expo/.routes.json +0 -3
- package/studio-v2/apps/web/dist/_expo/static/css/global-a4717de456877faacb88ee482aa99653.css +0 -1
- package/studio-v2/apps/web/dist/_expo/static/js/web/entry-5d96588cc8f2ee5c00754cef9ac6481d.js +0 -15648
- package/studio-v2/apps/web/dist/_expo/static/js/web/index-470f33f64d8c4f7b8d8da2632b2959c2.js +0 -4
- package/studio-v2/apps/web/dist/_expo/static/js/web/index-f7fcd21ae9d8dacf4c88ea5796614af0.js +0 -3
- package/studio-v2/apps/web/dist/_sitemap.html +0 -793
- package/studio-v2/apps/web/dist/assets/___node_modules/@expo/vector-icons/build/vendor/react-native-vector-icons/Fonts/AntDesign.3f78af31cca60105799838a1a7a59fbd.ttf +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@expo/vector-icons/build/vendor/react-native-vector-icons/Fonts/Entypo.31b5ffea3daddc69dd01a1f3d6cf63c5.ttf +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@expo/vector-icons/build/vendor/react-native-vector-icons/Fonts/EvilIcons.140c53a7643ea949007aa9a282153849.ttf +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@expo/vector-icons/build/vendor/react-native-vector-icons/Fonts/Feather.ca4b48e04dc1ce10bfbddb262c8b835f.ttf +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@expo/vector-icons/build/vendor/react-native-vector-icons/Fonts/FontAwesome.b06871f281fee6b241d60582ae9369b9.ttf +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@expo/vector-icons/build/vendor/react-native-vector-icons/Fonts/FontAwesome5_Brands.3b89dd103490708d19a95adcae52210e.ttf +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@expo/vector-icons/build/vendor/react-native-vector-icons/Fonts/FontAwesome5_Regular.1f77739ca9ff2188b539c36f30ffa2be.ttf +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@expo/vector-icons/build/vendor/react-native-vector-icons/Fonts/FontAwesome5_Solid.605ed7926cf39a2ad5ec2d1f9d391d3d.ttf +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@expo/vector-icons/build/vendor/react-native-vector-icons/Fonts/FontAwesome6_Brands.56c8d80832e37783f12c05db7c8849e2.ttf +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@expo/vector-icons/build/vendor/react-native-vector-icons/Fonts/FontAwesome6_Regular.370dd5af19f8364907b6e2c41f45dbbf.ttf +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@expo/vector-icons/build/vendor/react-native-vector-icons/Fonts/FontAwesome6_Solid.adec7d6f310bc577f05e8fe06a5daccf.ttf +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@expo/vector-icons/build/vendor/react-native-vector-icons/Fonts/Fontisto.b49ae8ab2dbccb02c4d11caaacf09eab.ttf +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@expo/vector-icons/build/vendor/react-native-vector-icons/Fonts/Foundation.e20945d7c929279ef7a6f1db184a4470.ttf +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@expo/vector-icons/build/vendor/react-native-vector-icons/Fonts/Ionicons.b4eb097d35f44ed943676fd56f6bdc51.ttf +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@expo/vector-icons/build/vendor/react-native-vector-icons/Fonts/MaterialCommunityIcons.6e435534bd35da5fef04168860a9b8fa.ttf +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@expo/vector-icons/build/vendor/react-native-vector-icons/Fonts/MaterialIcons.4e85bc9ebe07e0340c9c4fc2f6c38908.ttf +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@expo/vector-icons/build/vendor/react-native-vector-icons/Fonts/Octicons.871378c6eab492a3e689a9385dc45a12.ttf +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@expo/vector-icons/build/vendor/react-native-vector-icons/Fonts/SimpleLineIcons.d2285965fe34b05465047401b8595dd0.ttf +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@expo/vector-icons/build/vendor/react-native-vector-icons/Fonts/Zocial.1681f34aaca71b8dfb70756bca331eb2.ttf +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@react-navigation/drawer/lib/module/views/assets/toggle-drawer-icon.ae74bb20586a731af545e6b00fe14a09.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@react-navigation/elements/lib/module/assets/back-icon-mask.0a328cd9c1afd0afe8e3b1ec5165b1b4.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@react-navigation/elements/lib/module/assets/back-icon.35ba0eaec5a4f5ed12ca16fabeae451d.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@react-navigation/elements/lib/module/assets/clear-icon.c94f6478e7ae0cdd9f15de1fcb9e5e55.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@react-navigation/elements/lib/module/assets/clear-icon.c94f6478e7ae0cdd9f15de1fcb9e5e55@2x.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@react-navigation/elements/lib/module/assets/clear-icon.c94f6478e7ae0cdd9f15de1fcb9e5e55@3x.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@react-navigation/elements/lib/module/assets/clear-icon.c94f6478e7ae0cdd9f15de1fcb9e5e55@4x.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@react-navigation/elements/lib/module/assets/close-icon.808e1b1b9b53114ec2838071a7e6daa7.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@react-navigation/elements/lib/module/assets/close-icon.808e1b1b9b53114ec2838071a7e6daa7@2x.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@react-navigation/elements/lib/module/assets/close-icon.808e1b1b9b53114ec2838071a7e6daa7@3x.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@react-navigation/elements/lib/module/assets/close-icon.808e1b1b9b53114ec2838071a7e6daa7@4x.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/@react-navigation/elements/lib/module/assets/search-icon.286d67d3f74808a60a78d3ebf1a5fb57.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/expo-router/assets/arrow_down.017bc6ba3fc25503e5eb5e53826d48a8.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/expo-router/assets/error.d1ea1496f9057eb392d5bbf3732a61b7.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/expo-router/assets/file.19eeb73b9593a38f8e9f418337fc7d10.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/expo-router/assets/forward.d8b800c443b8972542883e0b9de2bdc6.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/expo-router/assets/pkg.ab19f4cbc543357183a20571f68380a3.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/expo-router/assets/react-navigation/elements/back-icon-mask.0a328cd9c1afd0afe8e3b1ec5165b1b4.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/expo-router/assets/react-navigation/elements/back-icon.35ba0eaec5a4f5ed12ca16fabeae451d.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/expo-router/assets/react-navigation/elements/clear-icon.c94f6478e7ae0cdd9f15de1fcb9e5e55.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/expo-router/assets/react-navigation/elements/clear-icon.c94f6478e7ae0cdd9f15de1fcb9e5e55@2x.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/expo-router/assets/react-navigation/elements/clear-icon.c94f6478e7ae0cdd9f15de1fcb9e5e55@3x.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/expo-router/assets/react-navigation/elements/clear-icon.c94f6478e7ae0cdd9f15de1fcb9e5e55@4x.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/expo-router/assets/react-navigation/elements/close-icon.808e1b1b9b53114ec2838071a7e6daa7.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/expo-router/assets/react-navigation/elements/close-icon.808e1b1b9b53114ec2838071a7e6daa7@2x.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/expo-router/assets/react-navigation/elements/close-icon.808e1b1b9b53114ec2838071a7e6daa7@3x.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/expo-router/assets/react-navigation/elements/close-icon.808e1b1b9b53114ec2838071a7e6daa7@4x.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/expo-router/assets/react-navigation/elements/search-icon.286d67d3f74808a60a78d3ebf1a5fb57.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/expo-router/assets/sitemap.412dd9275b6b48ad28f5e3d81bb1f626.png +0 -0
- package/studio-v2/apps/web/dist/assets/___node_modules/expo-router/assets/unmatched.20e71bdf79e3a97bf55fd9e164041578.png +0 -0
- package/studio-v2/apps/web/dist/index.html +0 -793
- /package/dist/{layout → registry}/index.js.map +0 -0
- /package/dist/{layout → registry}/index.mjs.map +0 -0
|
@@ -0,0 +1,200 @@
|
|
|
1
|
+
import { C as ColorScheme } from '../index-CpBqkIpd.mjs';
|
|
2
|
+
import { SpacingToken } from '../tokens/index.mjs';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Définit l'espacement autour d'un élément.
|
|
6
|
+
*/
|
|
7
|
+
interface LayoutPadding {
|
|
8
|
+
top?: SpacingToken;
|
|
9
|
+
bottom?: SpacingToken;
|
|
10
|
+
left?: SpacingToken;
|
|
11
|
+
right?: SpacingToken;
|
|
12
|
+
horizontal?: SpacingToken;
|
|
13
|
+
vertical?: SpacingToken;
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* Type pour définir l'arrière-plan d'une disposition, pouvant être une couleur unie ou un dégradé.
|
|
17
|
+
*/
|
|
18
|
+
type LayoutBackground = string | [string, string, ...string[]];
|
|
19
|
+
/**
|
|
20
|
+
* Rôles de couleurs extraits du schéma de couleurs du thème.
|
|
21
|
+
*/
|
|
22
|
+
type ThemeColorRole = Exclude<{
|
|
23
|
+
[K in keyof ColorScheme]: ColorScheme[K] extends string ? K : never;
|
|
24
|
+
}[keyof ColorScheme], undefined>;
|
|
25
|
+
/**
|
|
26
|
+
* Descripteur pour un emplacement (slot) pouvant accueillir des composants enfants.
|
|
27
|
+
*/
|
|
28
|
+
interface SlotDescriptor {
|
|
29
|
+
readonly name: string;
|
|
30
|
+
readonly label: string;
|
|
31
|
+
readonly required: boolean;
|
|
32
|
+
readonly kind?: "children" | "items" | "named" | "named-array";
|
|
33
|
+
readonly array?: boolean;
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* Types de propriétés supportés par le système.
|
|
37
|
+
*/
|
|
38
|
+
type PropType = "string" | "number" | "integer" | "url" | "icon" | "boolean" | "spacing" | "radius" | "shadow" | "color" | "background" | "padding" | "enum" | "ratio" | "json";
|
|
39
|
+
/**
|
|
40
|
+
* Décrit une propriété d'un composant, d'une disposition ou d'un bloc.
|
|
41
|
+
*/
|
|
42
|
+
interface PropDescriptor<T = unknown> {
|
|
43
|
+
readonly name: string;
|
|
44
|
+
readonly label: string;
|
|
45
|
+
readonly type: PropType;
|
|
46
|
+
readonly default?: T;
|
|
47
|
+
readonly themeDefault?: ThemeColorRole;
|
|
48
|
+
readonly description?: string;
|
|
49
|
+
readonly required?: boolean;
|
|
50
|
+
readonly options?: readonly string[];
|
|
51
|
+
readonly min?: number;
|
|
52
|
+
readonly max?: number;
|
|
53
|
+
readonly step?: number;
|
|
54
|
+
readonly platform?: "native" | "web" | "both";
|
|
55
|
+
readonly group?: "style" | "layout" | "behavior" | "content";
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* Catégories de dispositions.
|
|
59
|
+
*/
|
|
60
|
+
type LayoutCategory = "page" | "content" | "navigation" | "card" | "scroll" | "special";
|
|
61
|
+
/**
|
|
62
|
+
* Catégories de composants.
|
|
63
|
+
*/
|
|
64
|
+
type ComponentCategory = "input" | "action" | "display" | "feedback" | "overlay" | "media" | "navigation";
|
|
65
|
+
/**
|
|
66
|
+
* Catégories de blocs.
|
|
67
|
+
*/
|
|
68
|
+
type BlockCategory = "auth" | "profile" | "navigation" | "content" | "data" | "feedback" | "form" | "overlay" | "social" | "ecommerce" | "finance" | "onboarding" | "messaging" | "calendar" | "files" | "location" | "media";
|
|
69
|
+
/**
|
|
70
|
+
* Configuration pour les animations de type ressort (spring).
|
|
71
|
+
*/
|
|
72
|
+
interface SpringConfig {
|
|
73
|
+
readonly damping: number;
|
|
74
|
+
readonly stiffness: number;
|
|
75
|
+
readonly mass?: number;
|
|
76
|
+
readonly overshootClamping?: boolean;
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* Constantes spécifiques à une disposition (layout).
|
|
80
|
+
*/
|
|
81
|
+
interface LayoutConstants {
|
|
82
|
+
readonly springConfig?: SpringConfig;
|
|
83
|
+
readonly springSnap?: SpringConfig;
|
|
84
|
+
readonly springNoBounce?: SpringConfig;
|
|
85
|
+
readonly swipeThreshold?: number;
|
|
86
|
+
readonly flipThreshold?: number;
|
|
87
|
+
readonly exitDistance?: number;
|
|
88
|
+
readonly scaleFactor?: number;
|
|
89
|
+
readonly flipScaleFactor?: number;
|
|
90
|
+
readonly dezoomDuration?: number;
|
|
91
|
+
readonly flipDuration?: number;
|
|
92
|
+
readonly slideOutDuration?: number;
|
|
93
|
+
readonly exitLeft?: number;
|
|
94
|
+
readonly exitRight?: number;
|
|
95
|
+
}
|
|
96
|
+
/**
|
|
97
|
+
* Configuration de taille standardisée pour les composants.
|
|
98
|
+
*/
|
|
99
|
+
interface ComponentSizeConfig {
|
|
100
|
+
readonly height?: number;
|
|
101
|
+
readonly width?: number;
|
|
102
|
+
readonly px?: number;
|
|
103
|
+
readonly py?: number;
|
|
104
|
+
readonly fontSize?: number;
|
|
105
|
+
readonly iconSize?: number;
|
|
106
|
+
readonly borderRadius?: string | number;
|
|
107
|
+
readonly [key: string]: unknown;
|
|
108
|
+
}
|
|
109
|
+
/**
|
|
110
|
+
* Configuration de couleur standardisée pour les composants.
|
|
111
|
+
*/
|
|
112
|
+
interface ComponentColorConfig {
|
|
113
|
+
readonly bg?: ThemeColorRole | "transparent" | string;
|
|
114
|
+
readonly text?: ThemeColorRole | string;
|
|
115
|
+
readonly border?: ThemeColorRole | "transparent" | string;
|
|
116
|
+
readonly subtle?: ThemeColorRole | string | readonly [string, string];
|
|
117
|
+
readonly active?: ThemeColorRole | string;
|
|
118
|
+
readonly solid?: readonly [string, string];
|
|
119
|
+
readonly [key: string]: unknown;
|
|
120
|
+
}
|
|
121
|
+
/**
|
|
122
|
+
* Descripteur d'une variante de composant, permettant de surcharger certaines propriétés.
|
|
123
|
+
*/
|
|
124
|
+
interface VariantDescriptor<Props = Record<string, unknown>> {
|
|
125
|
+
readonly name: string;
|
|
126
|
+
readonly label: string;
|
|
127
|
+
readonly description?: string;
|
|
128
|
+
readonly overrides: Partial<Props>;
|
|
129
|
+
}
|
|
130
|
+
interface BaseMeta {
|
|
131
|
+
readonly id: string;
|
|
132
|
+
readonly label: string;
|
|
133
|
+
readonly description: string;
|
|
134
|
+
readonly props: readonly PropDescriptor<any>[];
|
|
135
|
+
readonly themeMapping?: Record<string, ThemeColorRole>;
|
|
136
|
+
readonly tags: readonly string[];
|
|
137
|
+
readonly customConfig?: Record<string, any>;
|
|
138
|
+
readonly enumMap?: Record<string, readonly string[]>;
|
|
139
|
+
}
|
|
140
|
+
/**
|
|
141
|
+
* Métadonnées spécifiques à une disposition (layout).
|
|
142
|
+
*/
|
|
143
|
+
interface LayoutMeta extends BaseMeta {
|
|
144
|
+
readonly category: LayoutCategory;
|
|
145
|
+
readonly slots: readonly SlotDescriptor[];
|
|
146
|
+
readonly constants?: LayoutConstants;
|
|
147
|
+
readonly responsive: boolean;
|
|
148
|
+
readonly animated: boolean;
|
|
149
|
+
readonly platforms?: readonly ("native" | "web")[];
|
|
150
|
+
readonly previewItemCount?: number;
|
|
151
|
+
readonly architecture?: {
|
|
152
|
+
readonly dependencies?: readonly string[];
|
|
153
|
+
};
|
|
154
|
+
/** @deprecated Use `architecture.dependencies` instead */
|
|
155
|
+
readonly dependencies?: readonly string[];
|
|
156
|
+
}
|
|
157
|
+
/**
|
|
158
|
+
* Métadonnées spécifiques à un composant.
|
|
159
|
+
*/
|
|
160
|
+
interface ComponentMeta<Props = any> extends BaseMeta {
|
|
161
|
+
readonly category: ComponentCategory;
|
|
162
|
+
readonly variants: readonly VariantDescriptor<Props>[];
|
|
163
|
+
readonly sizes?: readonly string[];
|
|
164
|
+
readonly sizeMap?: Record<string, ComponentSizeConfig>;
|
|
165
|
+
readonly colorMap?: Record<string, ComponentColorConfig>;
|
|
166
|
+
readonly platforms?: readonly ("native" | "web")[];
|
|
167
|
+
readonly capabilities?: {
|
|
168
|
+
readonly platforms?: readonly ("native" | "web")[];
|
|
169
|
+
};
|
|
170
|
+
readonly architecture?: {
|
|
171
|
+
readonly dependencies?: readonly string[];
|
|
172
|
+
};
|
|
173
|
+
}
|
|
174
|
+
/**
|
|
175
|
+
* Métadonnées spécifiques à un bloc.
|
|
176
|
+
*/
|
|
177
|
+
interface BlockMeta extends BaseMeta {
|
|
178
|
+
readonly category: BlockCategory;
|
|
179
|
+
readonly slots: readonly SlotDescriptor[];
|
|
180
|
+
readonly components: readonly string[];
|
|
181
|
+
}
|
|
182
|
+
/**
|
|
183
|
+
* Métadonnées spécifiques à un primitif.
|
|
184
|
+
*/
|
|
185
|
+
interface PrimitiveMeta extends BaseMeta {
|
|
186
|
+
readonly category: string;
|
|
187
|
+
readonly slots?: readonly SlotDescriptor[];
|
|
188
|
+
}
|
|
189
|
+
/**
|
|
190
|
+
* Type union représentant n'importe quelles métadonnées (disposition, composant, bloc ou primitif).
|
|
191
|
+
*/
|
|
192
|
+
type AnyMeta = LayoutMeta | ComponentMeta | BlockMeta | PrimitiveMeta;
|
|
193
|
+
/**
|
|
194
|
+
* Type utilitaire pour rendre toutes les propriétés optionnelles.
|
|
195
|
+
*/
|
|
196
|
+
type DefaultsOf<T extends Record<string, unknown>> = {
|
|
197
|
+
[K in keyof T]?: T[K];
|
|
198
|
+
};
|
|
199
|
+
|
|
200
|
+
export type { AnyMeta, BlockCategory, BlockMeta, ComponentCategory, ComponentColorConfig, ComponentMeta, ComponentSizeConfig, DefaultsOf, LayoutBackground, LayoutCategory, LayoutConstants, LayoutMeta, LayoutPadding, PrimitiveMeta, PropDescriptor, PropType, SlotDescriptor, SpringConfig, ThemeColorRole, VariantDescriptor };
|
|
@@ -0,0 +1,200 @@
|
|
|
1
|
+
import { C as ColorScheme } from '../index-CpBqkIpd.js';
|
|
2
|
+
import { SpacingToken } from '../tokens/index.js';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Définit l'espacement autour d'un élément.
|
|
6
|
+
*/
|
|
7
|
+
interface LayoutPadding {
|
|
8
|
+
top?: SpacingToken;
|
|
9
|
+
bottom?: SpacingToken;
|
|
10
|
+
left?: SpacingToken;
|
|
11
|
+
right?: SpacingToken;
|
|
12
|
+
horizontal?: SpacingToken;
|
|
13
|
+
vertical?: SpacingToken;
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* Type pour définir l'arrière-plan d'une disposition, pouvant être une couleur unie ou un dégradé.
|
|
17
|
+
*/
|
|
18
|
+
type LayoutBackground = string | [string, string, ...string[]];
|
|
19
|
+
/**
|
|
20
|
+
* Rôles de couleurs extraits du schéma de couleurs du thème.
|
|
21
|
+
*/
|
|
22
|
+
type ThemeColorRole = Exclude<{
|
|
23
|
+
[K in keyof ColorScheme]: ColorScheme[K] extends string ? K : never;
|
|
24
|
+
}[keyof ColorScheme], undefined>;
|
|
25
|
+
/**
|
|
26
|
+
* Descripteur pour un emplacement (slot) pouvant accueillir des composants enfants.
|
|
27
|
+
*/
|
|
28
|
+
interface SlotDescriptor {
|
|
29
|
+
readonly name: string;
|
|
30
|
+
readonly label: string;
|
|
31
|
+
readonly required: boolean;
|
|
32
|
+
readonly kind?: "children" | "items" | "named" | "named-array";
|
|
33
|
+
readonly array?: boolean;
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* Types de propriétés supportés par le système.
|
|
37
|
+
*/
|
|
38
|
+
type PropType = "string" | "number" | "integer" | "url" | "icon" | "boolean" | "spacing" | "radius" | "shadow" | "color" | "background" | "padding" | "enum" | "ratio" | "json";
|
|
39
|
+
/**
|
|
40
|
+
* Décrit une propriété d'un composant, d'une disposition ou d'un bloc.
|
|
41
|
+
*/
|
|
42
|
+
interface PropDescriptor<T = unknown> {
|
|
43
|
+
readonly name: string;
|
|
44
|
+
readonly label: string;
|
|
45
|
+
readonly type: PropType;
|
|
46
|
+
readonly default?: T;
|
|
47
|
+
readonly themeDefault?: ThemeColorRole;
|
|
48
|
+
readonly description?: string;
|
|
49
|
+
readonly required?: boolean;
|
|
50
|
+
readonly options?: readonly string[];
|
|
51
|
+
readonly min?: number;
|
|
52
|
+
readonly max?: number;
|
|
53
|
+
readonly step?: number;
|
|
54
|
+
readonly platform?: "native" | "web" | "both";
|
|
55
|
+
readonly group?: "style" | "layout" | "behavior" | "content";
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* Catégories de dispositions.
|
|
59
|
+
*/
|
|
60
|
+
type LayoutCategory = "page" | "content" | "navigation" | "card" | "scroll" | "special";
|
|
61
|
+
/**
|
|
62
|
+
* Catégories de composants.
|
|
63
|
+
*/
|
|
64
|
+
type ComponentCategory = "input" | "action" | "display" | "feedback" | "overlay" | "media" | "navigation";
|
|
65
|
+
/**
|
|
66
|
+
* Catégories de blocs.
|
|
67
|
+
*/
|
|
68
|
+
type BlockCategory = "auth" | "profile" | "navigation" | "content" | "data" | "feedback" | "form" | "overlay" | "social" | "ecommerce" | "finance" | "onboarding" | "messaging" | "calendar" | "files" | "location" | "media";
|
|
69
|
+
/**
|
|
70
|
+
* Configuration pour les animations de type ressort (spring).
|
|
71
|
+
*/
|
|
72
|
+
interface SpringConfig {
|
|
73
|
+
readonly damping: number;
|
|
74
|
+
readonly stiffness: number;
|
|
75
|
+
readonly mass?: number;
|
|
76
|
+
readonly overshootClamping?: boolean;
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* Constantes spécifiques à une disposition (layout).
|
|
80
|
+
*/
|
|
81
|
+
interface LayoutConstants {
|
|
82
|
+
readonly springConfig?: SpringConfig;
|
|
83
|
+
readonly springSnap?: SpringConfig;
|
|
84
|
+
readonly springNoBounce?: SpringConfig;
|
|
85
|
+
readonly swipeThreshold?: number;
|
|
86
|
+
readonly flipThreshold?: number;
|
|
87
|
+
readonly exitDistance?: number;
|
|
88
|
+
readonly scaleFactor?: number;
|
|
89
|
+
readonly flipScaleFactor?: number;
|
|
90
|
+
readonly dezoomDuration?: number;
|
|
91
|
+
readonly flipDuration?: number;
|
|
92
|
+
readonly slideOutDuration?: number;
|
|
93
|
+
readonly exitLeft?: number;
|
|
94
|
+
readonly exitRight?: number;
|
|
95
|
+
}
|
|
96
|
+
/**
|
|
97
|
+
* Configuration de taille standardisée pour les composants.
|
|
98
|
+
*/
|
|
99
|
+
interface ComponentSizeConfig {
|
|
100
|
+
readonly height?: number;
|
|
101
|
+
readonly width?: number;
|
|
102
|
+
readonly px?: number;
|
|
103
|
+
readonly py?: number;
|
|
104
|
+
readonly fontSize?: number;
|
|
105
|
+
readonly iconSize?: number;
|
|
106
|
+
readonly borderRadius?: string | number;
|
|
107
|
+
readonly [key: string]: unknown;
|
|
108
|
+
}
|
|
109
|
+
/**
|
|
110
|
+
* Configuration de couleur standardisée pour les composants.
|
|
111
|
+
*/
|
|
112
|
+
interface ComponentColorConfig {
|
|
113
|
+
readonly bg?: ThemeColorRole | "transparent" | string;
|
|
114
|
+
readonly text?: ThemeColorRole | string;
|
|
115
|
+
readonly border?: ThemeColorRole | "transparent" | string;
|
|
116
|
+
readonly subtle?: ThemeColorRole | string | readonly [string, string];
|
|
117
|
+
readonly active?: ThemeColorRole | string;
|
|
118
|
+
readonly solid?: readonly [string, string];
|
|
119
|
+
readonly [key: string]: unknown;
|
|
120
|
+
}
|
|
121
|
+
/**
|
|
122
|
+
* Descripteur d'une variante de composant, permettant de surcharger certaines propriétés.
|
|
123
|
+
*/
|
|
124
|
+
interface VariantDescriptor<Props = Record<string, unknown>> {
|
|
125
|
+
readonly name: string;
|
|
126
|
+
readonly label: string;
|
|
127
|
+
readonly description?: string;
|
|
128
|
+
readonly overrides: Partial<Props>;
|
|
129
|
+
}
|
|
130
|
+
interface BaseMeta {
|
|
131
|
+
readonly id: string;
|
|
132
|
+
readonly label: string;
|
|
133
|
+
readonly description: string;
|
|
134
|
+
readonly props: readonly PropDescriptor<any>[];
|
|
135
|
+
readonly themeMapping?: Record<string, ThemeColorRole>;
|
|
136
|
+
readonly tags: readonly string[];
|
|
137
|
+
readonly customConfig?: Record<string, any>;
|
|
138
|
+
readonly enumMap?: Record<string, readonly string[]>;
|
|
139
|
+
}
|
|
140
|
+
/**
|
|
141
|
+
* Métadonnées spécifiques à une disposition (layout).
|
|
142
|
+
*/
|
|
143
|
+
interface LayoutMeta extends BaseMeta {
|
|
144
|
+
readonly category: LayoutCategory;
|
|
145
|
+
readonly slots: readonly SlotDescriptor[];
|
|
146
|
+
readonly constants?: LayoutConstants;
|
|
147
|
+
readonly responsive: boolean;
|
|
148
|
+
readonly animated: boolean;
|
|
149
|
+
readonly platforms?: readonly ("native" | "web")[];
|
|
150
|
+
readonly previewItemCount?: number;
|
|
151
|
+
readonly architecture?: {
|
|
152
|
+
readonly dependencies?: readonly string[];
|
|
153
|
+
};
|
|
154
|
+
/** @deprecated Use `architecture.dependencies` instead */
|
|
155
|
+
readonly dependencies?: readonly string[];
|
|
156
|
+
}
|
|
157
|
+
/**
|
|
158
|
+
* Métadonnées spécifiques à un composant.
|
|
159
|
+
*/
|
|
160
|
+
interface ComponentMeta<Props = any> extends BaseMeta {
|
|
161
|
+
readonly category: ComponentCategory;
|
|
162
|
+
readonly variants: readonly VariantDescriptor<Props>[];
|
|
163
|
+
readonly sizes?: readonly string[];
|
|
164
|
+
readonly sizeMap?: Record<string, ComponentSizeConfig>;
|
|
165
|
+
readonly colorMap?: Record<string, ComponentColorConfig>;
|
|
166
|
+
readonly platforms?: readonly ("native" | "web")[];
|
|
167
|
+
readonly capabilities?: {
|
|
168
|
+
readonly platforms?: readonly ("native" | "web")[];
|
|
169
|
+
};
|
|
170
|
+
readonly architecture?: {
|
|
171
|
+
readonly dependencies?: readonly string[];
|
|
172
|
+
};
|
|
173
|
+
}
|
|
174
|
+
/**
|
|
175
|
+
* Métadonnées spécifiques à un bloc.
|
|
176
|
+
*/
|
|
177
|
+
interface BlockMeta extends BaseMeta {
|
|
178
|
+
readonly category: BlockCategory;
|
|
179
|
+
readonly slots: readonly SlotDescriptor[];
|
|
180
|
+
readonly components: readonly string[];
|
|
181
|
+
}
|
|
182
|
+
/**
|
|
183
|
+
* Métadonnées spécifiques à un primitif.
|
|
184
|
+
*/
|
|
185
|
+
interface PrimitiveMeta extends BaseMeta {
|
|
186
|
+
readonly category: string;
|
|
187
|
+
readonly slots?: readonly SlotDescriptor[];
|
|
188
|
+
}
|
|
189
|
+
/**
|
|
190
|
+
* Type union représentant n'importe quelles métadonnées (disposition, composant, bloc ou primitif).
|
|
191
|
+
*/
|
|
192
|
+
type AnyMeta = LayoutMeta | ComponentMeta | BlockMeta | PrimitiveMeta;
|
|
193
|
+
/**
|
|
194
|
+
* Type utilitaire pour rendre toutes les propriétés optionnelles.
|
|
195
|
+
*/
|
|
196
|
+
type DefaultsOf<T extends Record<string, unknown>> = {
|
|
197
|
+
[K in keyof T]?: T[K];
|
|
198
|
+
};
|
|
199
|
+
|
|
200
|
+
export type { AnyMeta, BlockCategory, BlockMeta, ComponentCategory, ComponentColorConfig, ComponentMeta, ComponentSizeConfig, DefaultsOf, LayoutBackground, LayoutCategory, LayoutConstants, LayoutMeta, LayoutPadding, PrimitiveMeta, PropDescriptor, PropType, SlotDescriptor, SpringConfig, ThemeColorRole, VariantDescriptor };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"index.js"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"names":[],"mappings":"","file":"index.mjs"}
|