@situaction/traquiste-mobile 1.0.0-next.2 → 1.0.0-next.3
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/package.json +8 -1
- package/.eslintrc.js +0 -5
- package/.releaserc +0 -12
- package/CLAUDE.md +0 -25
- package/app.json +0 -5
- package/bitbucket-pipelines.yml +0 -81
- package/build/components/Button/Button.stories.d.ts +0 -19
- package/build/components/Button/Button.stories.d.ts.map +0 -1
- package/build/components/Button/Button.stories.js +0 -95
- package/build/components/Button/Button.stories.js.map +0 -1
- package/build/components/ButtonAction/ButtonAction.stories.d.ts +0 -13
- package/build/components/ButtonAction/ButtonAction.stories.d.ts.map +0 -1
- package/build/components/ButtonAction/ButtonAction.stories.js +0 -51
- package/build/components/ButtonAction/ButtonAction.stories.js.map +0 -1
- package/build/components/ButtonMap/ButtonMap.stories.d.ts +0 -12
- package/build/components/ButtonMap/ButtonMap.stories.d.ts.map +0 -1
- package/build/components/ButtonMap/ButtonMap.stories.js +0 -36
- package/build/components/ButtonMap/ButtonMap.stories.js.map +0 -1
- package/build/components/ButtonMenu/ButtonMenu.stories.d.ts +0 -15
- package/build/components/ButtonMenu/ButtonMenu.stories.d.ts.map +0 -1
- package/build/components/ButtonMenu/ButtonMenu.stories.js +0 -52
- package/build/components/ButtonMenu/ButtonMenu.stories.js.map +0 -1
- package/build/components/FilterChip/FilterChip.stories.d.ts +0 -15
- package/build/components/FilterChip/FilterChip.stories.d.ts.map +0 -1
- package/build/components/FilterChip/FilterChip.stories.js +0 -55
- package/build/components/FilterChip/FilterChip.stories.js.map +0 -1
- package/docs/README.md +0 -73
- package/docs/eslint.config.js +0 -22
- package/docs/index.html +0 -16
- package/docs/package-lock.json +0 -5578
- package/docs/package.json +0 -37
- package/docs/public/favicon.svg +0 -1
- package/docs/public/icons.svg +0 -24
- package/docs/src/App.css +0 -184
- package/docs/src/App.tsx +0 -38
- package/docs/src/assets/hero.png +0 -0
- package/docs/src/assets/react.svg +0 -1
- package/docs/src/assets/vite.svg +0 -1
- package/docs/src/components/Layout.tsx +0 -108
- package/docs/src/components/LiveEditor.tsx +0 -294
- package/docs/src/components/PropsTable.tsx +0 -101
- package/docs/src/components/Sidebar.tsx +0 -103
- package/docs/src/components/TableOfContents.tsx +0 -75
- package/docs/src/context/ColorModeContext.tsx +0 -34
- package/docs/src/index.css +0 -76
- package/docs/src/lib/createComponentPage.tsx +0 -270
- package/docs/src/main.tsx +0 -13
- package/docs/src/pages/Examples.tsx +0 -273
- package/docs/src/pages/Home.tsx +0 -70
- package/docs/src/pages/components/button-action.ts +0 -88
- package/docs/src/pages/components/button-map.ts +0 -67
- package/docs/src/pages/components/button-menu.ts +0 -90
- package/docs/src/pages/components/button.ts +0 -158
- package/docs/src/pages/components/filter-chip.ts +0 -109
- package/docs/tsconfig.app.json +0 -32
- package/docs/tsconfig.json +0 -7
- package/docs/tsconfig.node.json +0 -24
- package/docs/vite.config.ts +0 -18
- package/ios/.xcode.env +0 -11
- package/ios/Podfile +0 -63
- package/ios/Podfile.properties.json +0 -4
- package/ios/situactiontraquistemobile/AppDelegate.swift +0 -69
- package/ios/situactiontraquistemobile/Images.xcassets/AppIcon.appiconset/Contents.json +0 -13
- package/ios/situactiontraquistemobile/Images.xcassets/Contents.json +0 -6
- package/ios/situactiontraquistemobile/Images.xcassets/SplashScreenLegacy.imageset/Contents.json +0 -21
- package/ios/situactiontraquistemobile/Images.xcassets/SplashScreenLegacy.imageset/SplashScreenLegacy.png +0 -0
- package/ios/situactiontraquistemobile/Info.plist +0 -53
- package/ios/situactiontraquistemobile/SplashScreen.storyboard +0 -47
- package/ios/situactiontraquistemobile/Supporting/Expo.plist +0 -6
- package/ios/situactiontraquistemobile/situactiontraquistemobile-Bridging-Header.h +0 -3
- package/ios/situactiontraquistemobile.xcodeproj/project.pbxproj +0 -432
- package/ios/situactiontraquistemobile.xcodeproj/xcshareddata/xcschemes/situactiontraquistemobile.xcscheme +0 -88
- package/jest.config.js +0 -197
- package/src/components/Button/Button.stories.tsx +0 -123
- package/src/components/ButtonAction/ButtonAction.stories.tsx +0 -67
- package/src/components/ButtonMap/ButtonMap.stories.tsx +0 -49
- package/src/components/ButtonMenu/ButtonMenu.stories.tsx +0 -68
- package/src/components/FilterChip/FilterChip.stories.tsx +0 -71
- package/tsconfig.json +0 -9
package/package.json
CHANGED
|
@@ -1,9 +1,16 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@situaction/traquiste-mobile",
|
|
3
|
-
"version": "1.0.0-next.
|
|
3
|
+
"version": "1.0.0-next.3",
|
|
4
4
|
"description": "React Native UI component library for Traquiste",
|
|
5
5
|
"main": "build/index.js",
|
|
6
6
|
"types": "build/index.d.ts",
|
|
7
|
+
"files": [
|
|
8
|
+
"build",
|
|
9
|
+
"src",
|
|
10
|
+
"!build/**/*.stories.*",
|
|
11
|
+
"!src/**/*.stories.*",
|
|
12
|
+
"!src/**/__tests__"
|
|
13
|
+
],
|
|
7
14
|
"scripts": {
|
|
8
15
|
"build": "expo-module build",
|
|
9
16
|
"clean": "expo-module clean",
|
package/.eslintrc.js
DELETED
package/.releaserc
DELETED
package/CLAUDE.md
DELETED
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
# Instructions Claude Code — traquiste-mobile
|
|
2
|
-
|
|
3
|
-
## Stack
|
|
4
|
-
Expo + TypeScript strict + StyleSheet natif. Zéro lib externe de styling.
|
|
5
|
-
|
|
6
|
-
## Conventions
|
|
7
|
-
- Commentaires en anglais, style concis
|
|
8
|
-
- /** Description composant */ en haut de chaque fichier
|
|
9
|
-
- Props documentées inline /** description */
|
|
10
|
-
|
|
11
|
-
## Commits
|
|
12
|
-
Convention semantic-release : feat / fix / chore / docs / test
|
|
13
|
-
|
|
14
|
-
## Tests
|
|
15
|
-
Jest + @testing-library/react-native.
|
|
16
|
-
Fichiers de test colocalisés : `ComponentName.test.tsx` dans le même dossier que le composant.
|
|
17
|
-
Lancer : `npm test -- --watchAll=false`
|
|
18
|
-
|
|
19
|
-
## Storybook
|
|
20
|
-
Local uniquement. Stories générées depuis le code du composant.
|
|
21
|
-
Format : même argTypes que traquiste-web (radio pour unions, boolean pour booléens).
|
|
22
|
-
|
|
23
|
-
## Doc Next.js
|
|
24
|
-
Une page par composant dans docs/pages/components/.
|
|
25
|
-
Playground interactif + éditeur code live bidirectionnel + props table.
|
package/app.json
DELETED
package/bitbucket-pipelines.yml
DELETED
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
image: node:22
|
|
2
|
-
|
|
3
|
-
definitions:
|
|
4
|
-
caches:
|
|
5
|
-
npm: ~/.npm
|
|
6
|
-
|
|
7
|
-
steps:
|
|
8
|
-
- step: &build
|
|
9
|
-
name: Build
|
|
10
|
-
caches: [npm]
|
|
11
|
-
script:
|
|
12
|
-
- npm ci --ignore-scripts
|
|
13
|
-
- npm run build
|
|
14
|
-
artifacts:
|
|
15
|
-
- build/**
|
|
16
|
-
|
|
17
|
-
- step: &test
|
|
18
|
-
name: Test
|
|
19
|
-
caches: [npm]
|
|
20
|
-
script:
|
|
21
|
-
- npm ci --ignore-scripts
|
|
22
|
-
- npm test -- --ci --passWithNoTests
|
|
23
|
-
|
|
24
|
-
- step: &build-docs
|
|
25
|
-
name: Build Docs
|
|
26
|
-
caches: [npm]
|
|
27
|
-
script:
|
|
28
|
-
- npm ci --ignore-scripts
|
|
29
|
-
- cd docs && npm ci --ignore-scripts && npm run build
|
|
30
|
-
artifacts:
|
|
31
|
-
- docs/dist/**
|
|
32
|
-
|
|
33
|
-
- step: &deploy-docs
|
|
34
|
-
name: Deploy Docs
|
|
35
|
-
clone:
|
|
36
|
-
enabled: false
|
|
37
|
-
script:
|
|
38
|
-
- pipe: atlassian/aws-s3-deploy:1.6.0
|
|
39
|
-
variables:
|
|
40
|
-
AWS_ACCESS_KEY_ID: $AWS_ACCESS_KEY_ID
|
|
41
|
-
AWS_SECRET_ACCESS_KEY: $AWS_SECRET_KEY
|
|
42
|
-
AWS_DEFAULT_REGION: "eu-west-3"
|
|
43
|
-
S3_BUCKET: $DOCS_S3_BUCKET
|
|
44
|
-
LOCAL_PATH: 'docs/dist'
|
|
45
|
-
DELETE_FLAG: 'true'
|
|
46
|
-
- pipe: atlassian/aws-cloudfront-invalidate:0.6.0
|
|
47
|
-
variables:
|
|
48
|
-
AWS_ACCESS_KEY_ID: $AWS_ACCESS_KEY_ID
|
|
49
|
-
AWS_SECRET_ACCESS_KEY: $AWS_SECRET_KEY
|
|
50
|
-
AWS_DEFAULT_REGION: "eu-west-3"
|
|
51
|
-
DISTRIBUTION_ID: $CLOUDFRONT_DISTRIBUTION_ID
|
|
52
|
-
|
|
53
|
-
- step: &publish
|
|
54
|
-
name: Publish
|
|
55
|
-
trigger: manual
|
|
56
|
-
script:
|
|
57
|
-
- npm ci --ignore-scripts
|
|
58
|
-
- npx semantic-release
|
|
59
|
-
|
|
60
|
-
pipelines:
|
|
61
|
-
pull-requests:
|
|
62
|
-
'**':
|
|
63
|
-
- step: *build
|
|
64
|
-
- step: *test
|
|
65
|
-
|
|
66
|
-
branches:
|
|
67
|
-
master:
|
|
68
|
-
- step: *build
|
|
69
|
-
- step: *test
|
|
70
|
-
- step:
|
|
71
|
-
<<: *build-docs
|
|
72
|
-
deployment: Production
|
|
73
|
-
- step:
|
|
74
|
-
<<: *deploy-docs
|
|
75
|
-
deployment: Production_AWS
|
|
76
|
-
- step: *publish
|
|
77
|
-
|
|
78
|
-
develop:
|
|
79
|
-
- step: *build
|
|
80
|
-
- step: *test
|
|
81
|
-
- step: *publish
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react-native';
|
|
2
|
-
import { type ButtonProps } from './Button';
|
|
3
|
-
type StoryArgs = ButtonProps & {
|
|
4
|
-
colorScheme: 'light' | 'dark';
|
|
5
|
-
};
|
|
6
|
-
declare const meta: Meta<StoryArgs>;
|
|
7
|
-
export default meta;
|
|
8
|
-
type Story = StoryObj<StoryArgs>;
|
|
9
|
-
export declare const Primary: Story;
|
|
10
|
-
export declare const Tertiary: Story;
|
|
11
|
-
export declare const Ghost: Story;
|
|
12
|
-
export declare const Destructive: Story;
|
|
13
|
-
export declare const WithIconLeft: Story;
|
|
14
|
-
export declare const WithIconRight: Story;
|
|
15
|
-
export declare const WithIconBoth: Story;
|
|
16
|
-
export declare const IconOnly: Story;
|
|
17
|
-
export declare const AllSizes: Story;
|
|
18
|
-
export declare const Disabled: Story;
|
|
19
|
-
//# sourceMappingURL=Button.stories.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Button.stories.d.ts","sourceRoot":"","sources":["../../../src/components/Button/Button.stories.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,yBAAyB,CAAC;AAG9D,OAAO,EAAU,KAAK,WAAW,EAAE,MAAM,UAAU,CAAC;AAEpD,KAAK,SAAS,GAAG,WAAW,GAAG;IAAE,WAAW,EAAE,OAAO,GAAG,MAAM,CAAA;CAAE,CAAC;AAEjE,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,SAAS,CA+BzB,CAAC;AAEF,eAAe,IAAI,CAAC;AAEpB,KAAK,KAAK,GAAG,QAAQ,CAAC,SAAS,CAAC,CAAC;AAEjC,eAAO,MAAM,OAAO,EAAE,KAErB,CAAC;AAEF,eAAO,MAAM,QAAQ,EAAE,KAEtB,CAAC;AAEF,eAAO,MAAM,KAAK,EAAE,KAEnB,CAAC;AAEF,eAAO,MAAM,WAAW,EAAE,KAEzB,CAAC;AAEF,eAAO,MAAM,YAAY,EAAE,KAS1B,CAAC;AAEF,eAAO,MAAM,aAAa,EAAE,KAO3B,CAAC;AAEF,eAAO,MAAM,YAAY,EAAE,KAO1B,CAAC;AAEF,eAAO,MAAM,QAAQ,EAAE,KAStB,CAAC;AAEF,eAAO,MAAM,QAAQ,EAAE,KAStB,CAAC;AAEF,eAAO,MAAM,QAAQ,EAAE,KAStB,CAAC"}
|
|
@@ -1,95 +0,0 @@
|
|
|
1
|
-
/** Storybook stories for the Button component */
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import { View } from 'react-native';
|
|
4
|
-
import { ArrowRight, Check, Trash, Plus, X, MagnifyingGlass } from 'phosphor-react-native';
|
|
5
|
-
import { Button } from './Button';
|
|
6
|
-
const meta = {
|
|
7
|
-
title: 'Components/Button',
|
|
8
|
-
component: Button,
|
|
9
|
-
render: ({ colorScheme: _colorScheme, ...args }) => <Button {...args}/>,
|
|
10
|
-
argTypes: {
|
|
11
|
-
colorScheme: {
|
|
12
|
-
control: { type: 'radio' },
|
|
13
|
-
options: ['light', 'dark'],
|
|
14
|
-
},
|
|
15
|
-
variant: {
|
|
16
|
-
control: { type: 'radio' },
|
|
17
|
-
options: ['primary', 'tertiary', 'ghost', 'destructive'],
|
|
18
|
-
},
|
|
19
|
-
size: {
|
|
20
|
-
control: { type: 'radio' },
|
|
21
|
-
options: ['S', 'M', 'L', 'XL'],
|
|
22
|
-
},
|
|
23
|
-
content: {
|
|
24
|
-
control: { type: 'radio' },
|
|
25
|
-
options: ['icon-only', 'icon-only-rounded', 'icon-both'],
|
|
26
|
-
},
|
|
27
|
-
disabled: { control: { type: 'boolean' } },
|
|
28
|
-
},
|
|
29
|
-
args: {
|
|
30
|
-
colorScheme: 'light',
|
|
31
|
-
label: 'Button',
|
|
32
|
-
variant: 'primary',
|
|
33
|
-
size: 'M',
|
|
34
|
-
content: 'icon-both',
|
|
35
|
-
disabled: false,
|
|
36
|
-
},
|
|
37
|
-
};
|
|
38
|
-
export default meta;
|
|
39
|
-
export const Primary = {
|
|
40
|
-
args: { variant: 'primary', label: 'Primary' },
|
|
41
|
-
};
|
|
42
|
-
export const Tertiary = {
|
|
43
|
-
args: { variant: 'tertiary', label: 'Tertiary' },
|
|
44
|
-
};
|
|
45
|
-
export const Ghost = {
|
|
46
|
-
args: { variant: 'ghost', label: 'Ghost' },
|
|
47
|
-
};
|
|
48
|
-
export const Destructive = {
|
|
49
|
-
args: { variant: 'destructive', label: 'Destructive' },
|
|
50
|
-
};
|
|
51
|
-
export const WithIconLeft = {
|
|
52
|
-
render: () => (<View style={{ gap: 12, padding: 16, alignItems: 'flex-start' }}>
|
|
53
|
-
<Button variant="primary" label="Rechercher" iconLeft={<MagnifyingGlass />}/>
|
|
54
|
-
<Button variant="tertiary" label="Ajouter" iconLeft={<Plus />}/>
|
|
55
|
-
<Button variant="ghost" label="Confirmer" iconLeft={<Check />}/>
|
|
56
|
-
<Button variant="destructive" label="Supprimer" iconLeft={<Trash />}/>
|
|
57
|
-
</View>),
|
|
58
|
-
};
|
|
59
|
-
export const WithIconRight = {
|
|
60
|
-
render: () => (<View style={{ gap: 12, padding: 16, alignItems: 'flex-start' }}>
|
|
61
|
-
<Button variant="primary" label="Suivant" iconRight={<ArrowRight />}/>
|
|
62
|
-
<Button variant="tertiary" label="Fermer" iconRight={<X />}/>
|
|
63
|
-
</View>),
|
|
64
|
-
};
|
|
65
|
-
export const WithIconBoth = {
|
|
66
|
-
render: () => (<View style={{ gap: 12, padding: 16, alignItems: 'flex-start' }}>
|
|
67
|
-
<Button variant="primary" label="Rechercher" iconLeft={<MagnifyingGlass />} iconRight={<ArrowRight />}/>
|
|
68
|
-
<Button variant="tertiary" label="Supprimer" iconLeft={<Trash />} iconRight={<X />}/>
|
|
69
|
-
</View>),
|
|
70
|
-
};
|
|
71
|
-
export const IconOnly = {
|
|
72
|
-
render: () => (<View style={{ flexDirection: 'row', gap: 12, padding: 16 }}>
|
|
73
|
-
<Button variant="primary" content="icon-only" iconLeft={<Plus />}/>
|
|
74
|
-
<Button variant="tertiary" content="icon-only" iconLeft={<MagnifyingGlass />}/>
|
|
75
|
-
<Button variant="ghost" content="icon-only" iconLeft={<X />}/>
|
|
76
|
-
<Button variant="destructive" content="icon-only-rounded" iconLeft={<Trash />}/>
|
|
77
|
-
</View>),
|
|
78
|
-
};
|
|
79
|
-
export const AllSizes = {
|
|
80
|
-
render: () => (<View style={{ gap: 12, padding: 16, alignItems: 'flex-start' }}>
|
|
81
|
-
<Button variant="primary" size="S" label="Small" iconLeft={<Check />}/>
|
|
82
|
-
<Button variant="primary" size="M" label="Medium" iconLeft={<Check />}/>
|
|
83
|
-
<Button variant="primary" size="L" label="Large" iconLeft={<Check />}/>
|
|
84
|
-
<Button variant="primary" size="XL" label="XLarge" iconLeft={<Check />}/>
|
|
85
|
-
</View>),
|
|
86
|
-
};
|
|
87
|
-
export const Disabled = {
|
|
88
|
-
render: () => (<View style={{ gap: 12, padding: 16, alignItems: 'flex-start' }}>
|
|
89
|
-
<Button variant="primary" disabled label="Primary" iconLeft={<Check />}/>
|
|
90
|
-
<Button variant="tertiary" disabled label="Tertiary" iconLeft={<Check />}/>
|
|
91
|
-
<Button variant="ghost" disabled label="Ghost" iconLeft={<Check />}/>
|
|
92
|
-
<Button variant="destructive" disabled label="Destructive" iconLeft={<Trash />}/>
|
|
93
|
-
</View>),
|
|
94
|
-
};
|
|
95
|
-
//# sourceMappingURL=Button.stories.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Button.stories.js","sourceRoot":"","sources":["../../../src/components/Button/Button.stories.tsx"],"names":[],"mappings":"AAAA,iDAAiD;AACjD,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AACpC,OAAO,EAAE,UAAU,EAAE,KAAK,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAC3F,OAAO,EAAE,MAAM,EAAoB,MAAM,UAAU,CAAC;AAIpD,MAAM,IAAI,GAAoB;IAC5B,KAAK,EAAE,mBAAmB;IAC1B,SAAS,EAAE,MAAM;IACjB,MAAM,EAAE,CAAC,EAAE,WAAW,EAAE,YAAY,EAAE,GAAG,IAAI,EAAE,EAAE,EAAE,CAAC,CAAC,MAAM,CAAC,IAAI,IAAI,CAAC,EAAG;IACxE,QAA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,CAAC,MAAM,QAAQ,GAAU;IAC7B,MAAM,EAAE,GAAG,EAAE,CAAC,CACZ,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,EAAE,GAAG,EAAE,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE,UAAU,EAAE,YAAY,EAAE,CAAC,CAC9D;MAAA,CAAC,MAAM,CAAC,OAAO,CAAC,SAAS,CAAK,QAAQ,CAAC,KAAK,CAAC,SAAS,CAAK,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,AAAD,EAAG,CAAC,EAC/E;MAAA,CAAC,MAAM,CAAC,OAAO,CAAC,UAAU,CAAI,QAAQ,CAAC,KAAK,CAAC,UAAU,CAAI,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,AAAD,EAAG,CAAC,EAC/E;MAAA,CAAC,MAAM,CAAC,OAAO,CAAC,OAAO,CAAO,QAAQ,CAAC,KAAK,CAAC,OAAO,CAAO,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,AAAD,EAAG,CAAC,EAC/E;MAAA,CAAC,MAAM,CAAC,OAAO,CAAC,aAAa,CAAC,QAAQ,CAAC,KAAK,CAAC,aAAa,CAAC,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,AAAD,EAAG,CAAC,EACjF;IAAA,EAAE,IAAI,CAAC,CACR;CACF,CAAC","sourcesContent":["/** Storybook stories for the Button component */\nimport React from 'react';\nimport type { Meta, StoryObj } from '@storybook/react-native';\nimport { View } from 'react-native';\nimport { ArrowRight, Check, Trash, Plus, X, MagnifyingGlass } from 'phosphor-react-native';\nimport { Button, type ButtonProps } from './Button';\n\ntype StoryArgs = ButtonProps & { colorScheme: 'light' | 'dark' };\n\nconst meta: Meta<StoryArgs> = {\n title: 'Components/Button',\n component: Button,\n render: ({ colorScheme: _colorScheme, ...args }) => <Button {...args} />,\n argTypes: {\n colorScheme: {\n control: { type: 'radio' },\n options: ['light', 'dark'],\n },\n variant: {\n control: { type: 'radio' },\n options: ['primary', 'tertiary', 'ghost', 'destructive'],\n },\n size: {\n control: { type: 'radio' },\n options: ['S', 'M', 'L', 'XL'],\n },\n content: {\n control: { type: 'radio' },\n options: ['icon-only', 'icon-only-rounded', 'icon-both'],\n },\n disabled: { control: { type: 'boolean' } },\n },\n args: {\n colorScheme: 'light',\n label: 'Button',\n variant: 'primary',\n size: 'M',\n content: 'icon-both',\n disabled: false,\n },\n};\n\nexport default meta;\n\ntype Story = StoryObj<StoryArgs>;\n\nexport const Primary: Story = {\n args: { variant: 'primary', label: 'Primary' },\n};\n\nexport const Tertiary: Story = {\n args: { variant: 'tertiary', label: 'Tertiary' },\n};\n\nexport const Ghost: Story = {\n args: { variant: 'ghost', label: 'Ghost' },\n};\n\nexport const Destructive: Story = {\n args: { variant: 'destructive', label: 'Destructive' },\n};\n\nexport const WithIconLeft: Story = {\n render: () => (\n <View style={{ gap: 12, padding: 16, alignItems: 'flex-start' }}>\n <Button variant=\"primary\" label=\"Rechercher\" iconLeft={<MagnifyingGlass />} />\n <Button variant=\"tertiary\" label=\"Ajouter\" iconLeft={<Plus />} />\n <Button variant=\"ghost\" label=\"Confirmer\" iconLeft={<Check />} />\n <Button variant=\"destructive\" label=\"Supprimer\" iconLeft={<Trash />} />\n </View>\n ),\n};\n\nexport const WithIconRight: Story = {\n render: () => (\n <View style={{ gap: 12, padding: 16, alignItems: 'flex-start' }}>\n <Button variant=\"primary\" label=\"Suivant\" iconRight={<ArrowRight />} />\n <Button variant=\"tertiary\" label=\"Fermer\" iconRight={<X />} />\n </View>\n ),\n};\n\nexport const WithIconBoth: Story = {\n render: () => (\n <View style={{ gap: 12, padding: 16, alignItems: 'flex-start' }}>\n <Button variant=\"primary\" label=\"Rechercher\" iconLeft={<MagnifyingGlass />} iconRight={<ArrowRight />} />\n <Button variant=\"tertiary\" label=\"Supprimer\" iconLeft={<Trash />} iconRight={<X />} />\n </View>\n ),\n};\n\nexport const IconOnly: Story = {\n render: () => (\n <View style={{ flexDirection: 'row', gap: 12, padding: 16 }}>\n <Button variant=\"primary\" content=\"icon-only\" iconLeft={<Plus />} />\n <Button variant=\"tertiary\" content=\"icon-only\" iconLeft={<MagnifyingGlass />} />\n <Button variant=\"ghost\" content=\"icon-only\" iconLeft={<X />} />\n <Button variant=\"destructive\" content=\"icon-only-rounded\" iconLeft={<Trash />} />\n </View>\n ),\n};\n\nexport const AllSizes: Story = {\n render: () => (\n <View style={{ gap: 12, padding: 16, alignItems: 'flex-start' }}>\n <Button variant=\"primary\" size=\"S\" label=\"Small\" iconLeft={<Check />} />\n <Button variant=\"primary\" size=\"M\" label=\"Medium\" iconLeft={<Check />} />\n <Button variant=\"primary\" size=\"L\" label=\"Large\" iconLeft={<Check />} />\n <Button variant=\"primary\" size=\"XL\" label=\"XLarge\" iconLeft={<Check />} />\n </View>\n ),\n};\n\nexport const Disabled: Story = {\n render: () => (\n <View style={{ gap: 12, padding: 16, alignItems: 'flex-start' }}>\n <Button variant=\"primary\" disabled label=\"Primary\" iconLeft={<Check />} />\n <Button variant=\"tertiary\" disabled label=\"Tertiary\" iconLeft={<Check />} />\n <Button variant=\"ghost\" disabled label=\"Ghost\" iconLeft={<Check />} />\n <Button variant=\"destructive\" disabled label=\"Destructive\" iconLeft={<Trash />} />\n </View>\n ),\n};"]}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react-native';
|
|
2
|
-
import { type ButtonActionProps } from './ButtonAction';
|
|
3
|
-
type StoryArgs = ButtonActionProps & {
|
|
4
|
-
colorScheme: 'light' | 'dark';
|
|
5
|
-
};
|
|
6
|
-
declare const meta: Meta<StoryArgs>;
|
|
7
|
-
export default meta;
|
|
8
|
-
type Story = StoryObj<StoryArgs>;
|
|
9
|
-
export declare const Default: Story;
|
|
10
|
-
export declare const Disabled: Story;
|
|
11
|
-
export declare const AllSizes: Story;
|
|
12
|
-
export declare const AllIcons: Story;
|
|
13
|
-
//# sourceMappingURL=ButtonAction.stories.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ButtonAction.stories.d.ts","sourceRoot":"","sources":["../../../src/components/ButtonAction/ButtonAction.stories.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,yBAAyB,CAAC;AAG9D,OAAO,EAAgB,KAAK,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AAEtE,KAAK,SAAS,GAAG,iBAAiB,GAAG;IAAE,WAAW,EAAE,OAAO,GAAG,MAAM,CAAA;CAAE,CAAC;AAEvE,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,SAAS,CAsBzB,CAAC;AAEF,eAAe,IAAI,CAAC;AAEpB,KAAK,KAAK,GAAG,QAAQ,CAAC,SAAS,CAAC,CAAC;AAEjC,eAAO,MAAM,OAAO,EAAE,KAAU,CAAC;AAEjC,eAAO,MAAM,QAAQ,EAAE,KAEtB,CAAC;AAEF,eAAO,MAAM,QAAQ,EAAE,KAWtB,CAAC;AAEF,eAAO,MAAM,QAAQ,EAAE,KAUtB,CAAC"}
|
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
/** Storybook stories for the ButtonAction component */
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import { View } from 'react-native';
|
|
4
|
-
import { X, DotsThree, ArrowLeft, MagnifyingGlass, Bell } from 'phosphor-react-native';
|
|
5
|
-
import { ButtonAction } from './ButtonAction';
|
|
6
|
-
const meta = {
|
|
7
|
-
title: 'Components/ButtonAction',
|
|
8
|
-
component: ButtonAction,
|
|
9
|
-
render: ({ colorScheme: _colorScheme, ...args }) => (<ButtonAction {...args} icon={<X />}/>),
|
|
10
|
-
argTypes: {
|
|
11
|
-
colorScheme: {
|
|
12
|
-
control: { type: 'radio' },
|
|
13
|
-
options: ['light', 'dark'],
|
|
14
|
-
},
|
|
15
|
-
size: {
|
|
16
|
-
control: { type: 'radio' },
|
|
17
|
-
options: ['XS', 'S', 'M', 'L', 'XL', 'XXL'],
|
|
18
|
-
},
|
|
19
|
-
disabled: { control: { type: 'boolean' } },
|
|
20
|
-
},
|
|
21
|
-
args: {
|
|
22
|
-
colorScheme: 'light',
|
|
23
|
-
size: 'M',
|
|
24
|
-
disabled: false,
|
|
25
|
-
},
|
|
26
|
-
};
|
|
27
|
-
export default meta;
|
|
28
|
-
export const Default = {};
|
|
29
|
-
export const Disabled = {
|
|
30
|
-
args: { disabled: true },
|
|
31
|
-
};
|
|
32
|
-
export const AllSizes = {
|
|
33
|
-
render: () => (<View style={{ flexDirection: 'row', gap: 16, padding: 16, alignItems: 'center' }}>
|
|
34
|
-
<ButtonAction size="XS" icon={<X />}/>
|
|
35
|
-
<ButtonAction size="S" icon={<X />}/>
|
|
36
|
-
<ButtonAction size="M" icon={<X />}/>
|
|
37
|
-
<ButtonAction size="L" icon={<X />}/>
|
|
38
|
-
<ButtonAction size="XL" icon={<X />}/>
|
|
39
|
-
<ButtonAction size="XXL" icon={<X />}/>
|
|
40
|
-
</View>),
|
|
41
|
-
};
|
|
42
|
-
export const AllIcons = {
|
|
43
|
-
render: () => (<View style={{ flexDirection: 'row', gap: 16, padding: 16, alignItems: 'center' }}>
|
|
44
|
-
<ButtonAction size="L" icon={<ArrowLeft />}/>
|
|
45
|
-
<ButtonAction size="L" icon={<MagnifyingGlass />}/>
|
|
46
|
-
<ButtonAction size="L" icon={<Bell />}/>
|
|
47
|
-
<ButtonAction size="L" icon={<DotsThree />}/>
|
|
48
|
-
<ButtonAction size="L" icon={<X />}/>
|
|
49
|
-
</View>),
|
|
50
|
-
};
|
|
51
|
-
//# sourceMappingURL=ButtonAction.stories.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ButtonAction.stories.js","sourceRoot":"","sources":["../../../src/components/ButtonAction/ButtonAction.stories.tsx"],"names":[],"mappings":"AAAA,uDAAuD;AACvD,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AACpC,OAAO,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,CAAC,YAAY,CAAC,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,AAAD,EAAG,CAAC,EACtC;MAAA,CAAC,YAAY,CAAC,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS,CAAC,AAAD,EAAG,CAAC,EAC3C;MAAA,CAAC,YAAY,CAAC,IAAI,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,AAAD,EAAG,CAAC,EACrC;IAAA,EAAE,IAAI,CAAC,CACR;CACF,CAAC","sourcesContent":["/** Storybook stories for the ButtonAction component */\nimport React from 'react';\nimport type { Meta, StoryObj } from '@storybook/react-native';\nimport { View } from 'react-native';\nimport { X, DotsThree, ArrowLeft, MagnifyingGlass, Bell } from 'phosphor-react-native';\nimport { ButtonAction, type ButtonActionProps } from './ButtonAction';\n\ntype StoryArgs = ButtonActionProps & { colorScheme: 'light' | 'dark' };\n\nconst meta: Meta<StoryArgs> = {\n title: 'Components/ButtonAction',\n component: ButtonAction,\n render: ({ colorScheme: _colorScheme, ...args }) => (\n <ButtonAction {...args} icon={<X />} />\n ),\n argTypes: {\n colorScheme: {\n control: { type: 'radio' },\n options: ['light', 'dark'],\n },\n size: {\n control: { type: 'radio' },\n options: ['XS', 'S', 'M', 'L', 'XL', 'XXL'],\n },\n disabled: { control: { type: 'boolean' } },\n },\n args: {\n colorScheme: 'light',\n size: 'M',\n disabled: false,\n },\n};\n\nexport default meta;\n\ntype Story = StoryObj<StoryArgs>;\n\nexport const Default: Story = {};\n\nexport const Disabled: Story = {\n args: { disabled: true },\n};\n\nexport const AllSizes: Story = {\n render: () => (\n <View style={{ flexDirection: 'row', gap: 16, padding: 16, alignItems: 'center' }}>\n <ButtonAction size=\"XS\" icon={<X />} />\n <ButtonAction size=\"S\" icon={<X />} />\n <ButtonAction size=\"M\" icon={<X />} />\n <ButtonAction size=\"L\" icon={<X />} />\n <ButtonAction size=\"XL\" icon={<X />} />\n <ButtonAction size=\"XXL\" icon={<X />} />\n </View>\n ),\n};\n\nexport const AllIcons: Story = {\n render: () => (\n <View style={{ flexDirection: 'row', gap: 16, padding: 16, alignItems: 'center' }}>\n <ButtonAction size=\"L\" icon={<ArrowLeft />} />\n <ButtonAction size=\"L\" icon={<MagnifyingGlass />} />\n <ButtonAction size=\"L\" icon={<Bell />} />\n <ButtonAction size=\"L\" icon={<DotsThree />} />\n <ButtonAction size=\"L\" icon={<X />} />\n </View>\n ),\n};"]}
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react-native';
|
|
2
|
-
import { type ButtonMapProps } from './ButtonMap';
|
|
3
|
-
type StoryArgs = ButtonMapProps & {
|
|
4
|
-
colorScheme: 'light' | 'dark';
|
|
5
|
-
};
|
|
6
|
-
declare const meta: Meta<StoryArgs>;
|
|
7
|
-
export default meta;
|
|
8
|
-
type Story = StoryObj<StoryArgs>;
|
|
9
|
-
export declare const Default: Story;
|
|
10
|
-
export declare const Disabled: Story;
|
|
11
|
-
export declare const MapControls: Story;
|
|
12
|
-
//# sourceMappingURL=ButtonMap.stories.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ButtonMap.stories.d.ts","sourceRoot":"","sources":["../../../src/components/ButtonMap/ButtonMap.stories.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,yBAAyB,CAAC;AAG9D,OAAO,EAAa,KAAK,cAAc,EAAE,MAAM,aAAa,CAAC;AAE7D,KAAK,SAAS,GAAG,cAAc,GAAG;IAAE,WAAW,EAAE,OAAO,GAAG,MAAM,CAAA;CAAE,CAAC;AAEpE,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,SAAS,CAiBzB,CAAC;AAEF,eAAe,IAAI,CAAC;AAEpB,KAAK,KAAK,GAAG,QAAQ,CAAC,SAAS,CAAC,CAAC;AAEjC,eAAO,MAAM,OAAO,EAAE,KAAU,CAAC;AAEjC,eAAO,MAAM,QAAQ,EAAE,KAEtB,CAAC;AAEF,eAAO,MAAM,WAAW,EAAE,KAUzB,CAAC"}
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
/** Storybook stories for the ButtonMap component */
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import { View } from 'react-native';
|
|
4
|
-
import { Plus, Minus, Crosshair, MapPin, MagnifyingGlass } from 'phosphor-react-native';
|
|
5
|
-
import { ButtonMap } from './ButtonMap';
|
|
6
|
-
const meta = {
|
|
7
|
-
title: 'Components/ButtonMap',
|
|
8
|
-
component: ButtonMap,
|
|
9
|
-
render: ({ colorScheme: _colorScheme, ...args }) => (<ButtonMap {...args} icon={<Crosshair />}/>),
|
|
10
|
-
argTypes: {
|
|
11
|
-
colorScheme: {
|
|
12
|
-
control: { type: 'radio' },
|
|
13
|
-
options: ['light', 'dark'],
|
|
14
|
-
},
|
|
15
|
-
disabled: { control: { type: 'boolean' } },
|
|
16
|
-
},
|
|
17
|
-
args: {
|
|
18
|
-
colorScheme: 'light',
|
|
19
|
-
disabled: false,
|
|
20
|
-
},
|
|
21
|
-
};
|
|
22
|
-
export default meta;
|
|
23
|
-
export const Default = {};
|
|
24
|
-
export const Disabled = {
|
|
25
|
-
args: { disabled: true },
|
|
26
|
-
};
|
|
27
|
-
export const MapControls = {
|
|
28
|
-
render: () => (<View style={{ gap: 8, padding: 16, alignItems: 'flex-start' }}>
|
|
29
|
-
<ButtonMap icon={<Plus />}/>
|
|
30
|
-
<ButtonMap icon={<Minus />}/>
|
|
31
|
-
<ButtonMap icon={<Crosshair />}/>
|
|
32
|
-
<ButtonMap icon={<MapPin />}/>
|
|
33
|
-
<ButtonMap icon={<MagnifyingGlass />} disabled/>
|
|
34
|
-
</View>),
|
|
35
|
-
};
|
|
36
|
-
//# sourceMappingURL=ButtonMap.stories.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ButtonMap.stories.js","sour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EAAE,UAAU,EAAE,YAAY,EAAE,CAAC,CAC7D;MAAA,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,AAAD,EAAG,CAAC,EAC1B;MAAA,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC,AAAD,EAAG,CAAC,EAC3B;MAAA,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS,CAAC,AAAD,EAAG,CAAC,EAC/B;MAAA,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,AAAD,EAAG,CAAC,EAC5B;MAAA,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC,CAAC,eAAe,CAAC,AAAD,EAAG,CAAC,CAAC,QAAQ,EAChD;IAAA,EAAE,IAAI,CAAC,CACR;CACF,CAAC","sourcesContent":["/** Storybook stories for the ButtonMap component */\nimport React from 'react';\nimport type { Meta, StoryObj } from '@storybook/react-native';\nimport { View } from 'react-native';\nimport { Plus, Minus, Crosshair, MapPin, MagnifyingGlass } from 'phosphor-react-native';\nimport { ButtonMap, type ButtonMapProps } from './ButtonMap';\n\ntype StoryArgs = ButtonMapProps & { colorScheme: 'light' | 'dark' };\n\nconst meta: Meta<StoryArgs> = {\n title: 'Components/ButtonMap',\n component: ButtonMap,\n render: ({ colorScheme: _colorScheme, ...args }) => (\n <ButtonMap {...args} icon={<Crosshair />} />\n ),\n argTypes: {\n colorScheme: {\n control: { type: 'radio' },\n options: ['light', 'dark'],\n },\n disabled: { control: { type: 'boolean' } },\n },\n args: {\n colorScheme: 'light',\n disabled: false,\n },\n};\n\nexport default meta;\n\ntype Story = StoryObj<StoryArgs>;\n\nexport const Default: Story = {};\n\nexport const Disabled: Story = {\n args: { disabled: true },\n};\n\nexport const MapControls: Story = {\n render: () => (\n <View style={{ gap: 8, padding: 16, alignItems: 'flex-start' }}>\n <ButtonMap icon={<Plus />} />\n <ButtonMap icon={<Minus />} />\n <ButtonMap icon={<Crosshair />} />\n <ButtonMap icon={<MapPin />} />\n <ButtonMap icon={<MagnifyingGlass />} disabled />\n </View>\n ),\n};"]}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react-native';
|
|
2
|
-
import { type ButtonMenuProps } from './ButtonMenu';
|
|
3
|
-
type StoryArgs = ButtonMenuProps & {
|
|
4
|
-
colorScheme: 'light' | 'dark';
|
|
5
|
-
};
|
|
6
|
-
declare const meta: Meta<StoryArgs>;
|
|
7
|
-
export default meta;
|
|
8
|
-
type Story = StoryObj<StoryArgs>;
|
|
9
|
-
export declare const Default: Story;
|
|
10
|
-
export declare const Active: Story;
|
|
11
|
-
export declare const Disabled: Story;
|
|
12
|
-
export declare const WithNotif: Story;
|
|
13
|
-
export declare const ActiveWithNotif: Story;
|
|
14
|
-
export declare const AllStates: Story;
|
|
15
|
-
//# sourceMappingURL=ButtonMenu.stories.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ButtonMenu.stories.d.ts","sourceRoot":"","sources":["../../../src/components/ButtonMenu/ButtonMenu.stories.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,yBAAyB,CAAC;AAG9D,OAAO,EAAc,KAAK,eAAe,EAAE,MAAM,cAAc,CAAC;AAEhE,KAAK,SAAS,GAAG,eAAe,GAAG;IAAE,WAAW,EAAE,OAAO,GAAG,MAAM,CAAA;CAAE,CAAC;AAErE,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,SAAS,CAsBzB,CAAC;AAEF,eAAe,IAAI,CAAC;AAEpB,KAAK,KAAK,GAAG,QAAQ,CAAC,SAAS,CAAC,CAAC;AAEjC,eAAO,MAAM,OAAO,EAAE,KAErB,CAAC;AAEF,eAAO,MAAM,MAAM,EAAE,KAEpB,CAAC;AAEF,eAAO,MAAM,QAAQ,EAAE,KAEtB,CAAC;AAEF,eAAO,MAAM,SAAS,EAAE,KAEvB,CAAC;AAEF,eAAO,MAAM,eAAe,EAAE,KAE7B,CAAC;AAEF,eAAO,MAAM,SAAS,EAAE,KAUvB,CAAC"}
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
/** Storybook stories for the ButtonMenu component */
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import { View } from 'react-native';
|
|
4
|
-
import { House, MagnifyingGlass, Bell, Gear } from 'phosphor-react-native';
|
|
5
|
-
import { ButtonMenu } from './ButtonMenu';
|
|
6
|
-
const meta = {
|
|
7
|
-
title: 'Components/ButtonMenu',
|
|
8
|
-
component: ButtonMenu,
|
|
9
|
-
render: ({ colorScheme: _colorScheme, ...args }) => (<ButtonMenu {...args} icon={<House />}/>),
|
|
10
|
-
argTypes: {
|
|
11
|
-
colorScheme: {
|
|
12
|
-
control: { type: 'radio' },
|
|
13
|
-
options: ['light', 'dark'],
|
|
14
|
-
},
|
|
15
|
-
state: {
|
|
16
|
-
control: { type: 'radio' },
|
|
17
|
-
options: ['default', 'active', 'disabled'],
|
|
18
|
-
},
|
|
19
|
-
notif: { control: { type: 'boolean' } },
|
|
20
|
-
},
|
|
21
|
-
args: {
|
|
22
|
-
colorScheme: 'light',
|
|
23
|
-
state: 'default',
|
|
24
|
-
notif: false,
|
|
25
|
-
},
|
|
26
|
-
};
|
|
27
|
-
export default meta;
|
|
28
|
-
export const Default = {
|
|
29
|
-
args: { state: 'default' },
|
|
30
|
-
};
|
|
31
|
-
export const Active = {
|
|
32
|
-
args: { state: 'active' },
|
|
33
|
-
};
|
|
34
|
-
export const Disabled = {
|
|
35
|
-
args: { state: 'disabled' },
|
|
36
|
-
};
|
|
37
|
-
export const WithNotif = {
|
|
38
|
-
args: { state: 'default', notif: true },
|
|
39
|
-
};
|
|
40
|
-
export const ActiveWithNotif = {
|
|
41
|
-
args: { state: 'active', notif: true },
|
|
42
|
-
};
|
|
43
|
-
export const AllStates = {
|
|
44
|
-
render: () => (<View style={{ flexDirection: 'row', gap: 12, padding: 16 }}>
|
|
45
|
-
<ButtonMenu state="default" icon={<House />}/>
|
|
46
|
-
<ButtonMenu state="active" icon={<MagnifyingGlass />}/>
|
|
47
|
-
<ButtonMenu state="disabled" icon={<Gear />}/>
|
|
48
|
-
<ButtonMenu state="default" icon={<Bell />} notif/>
|
|
49
|
-
<ButtonMenu state="active" icon={<Bell />} notif/>
|
|
50
|
-
</View>),
|
|
51
|
-
};
|
|
52
|
-
//# sourceMappingURL=ButtonMenu.stories.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ButtonMenu.stories.js","sourceRoot":"","sources":["../../../src/components/ButtonMenu/ButtonMenu.stories.tsx"],"names":[],"mappings":"AAAA,qDAAqD;AACrD,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AACpC,OAAO,EAAE,KAAK,EAAE,eAAe,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAC3E,OAAO,EAAE,UAAU,EAAwB,MAAM,cAAc,CAAC;AAIhE,MAAM,IAAI,GAAoB;IAC5B,KAAK,EAAE,uBAAuB;IAC9B,SAAS,EAAE,UAAU;IACrB,MAAM,EAAE,CAAC,EAAE,WAAW,EAAE,YAAY,EAAE,GAAG,IAAI,EAAE,EAAE,EAAE,CAAC,CAClD,CAAC,UAAU,CAAC,IAAI,IAAI,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC,AAAD,EAAG,CAAC,EAAG,CAC1C;IACD,QAAQ,EAAE;QACR,WAAW,EAAE;YACX,OAAO,EAAE,EAAE,IAAI,EAAE,OAAO,EAAE;YAC1B,OAAO,EAAE,CAAC,OAAO,EAAE,MAAM,CAAC;SAC3B;QACD,KAAK,EAAE;YACL,OAAO,EAAE,EAAE,IAAI,EAAE,OAAO,EAAE;YAC1B,OAAO,EAAE,CAAC,SAAS,EAAE,QAAQ,EAAE,UAAU,CAAC;SAC3C;QACD,KAA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CAAC,IAAI,CAAC,AAAD,EAAG,CAAC,EAC5C;MAAA,CAAC,UAAU,CAAC,KAAK,CAAC,SAAS,CAAE,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,AAAD,EAAG,CAAC,CAAC,KAAK,EAClD;MAAA,CAAC,UAAU,CAAC,KAAK,CAAC,QAAQ,CAAG,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,AAAD,EAAG,CAAC,CAAC,KAAK,EACpD;IAAA,EAAE,IAAI,CAAC,CACR;CACF,CAAC","sourcesContent":["/** Storybook stories for the ButtonMenu component */\nimport React from 'react';\nimport type { Meta, StoryObj } from '@storybook/react-native';\nimport { View } from 'react-native';\nimport { House, MagnifyingGlass, Bell, Gear } from 'phosphor-react-native';\nimport { ButtonMenu, type ButtonMenuProps } from './ButtonMenu';\n\ntype StoryArgs = ButtonMenuProps & { colorScheme: 'light' | 'dark' };\n\nconst meta: Meta<StoryArgs> = {\n title: 'Components/ButtonMenu',\n component: ButtonMenu,\n render: ({ colorScheme: _colorScheme, ...args }) => (\n <ButtonMenu {...args} icon={<House />} />\n ),\n argTypes: {\n colorScheme: {\n control: { type: 'radio' },\n options: ['light', 'dark'],\n },\n state: {\n control: { type: 'radio' },\n options: ['default', 'active', 'disabled'],\n },\n notif: { control: { type: 'boolean' } },\n },\n args: {\n colorScheme: 'light',\n state: 'default',\n notif: false,\n },\n};\n\nexport default meta;\n\ntype Story = StoryObj<StoryArgs>;\n\nexport const Default: Story = {\n args: { state: 'default' },\n};\n\nexport const Active: Story = {\n args: { state: 'active' },\n};\n\nexport const Disabled: Story = {\n args: { state: 'disabled' },\n};\n\nexport const WithNotif: Story = {\n args: { state: 'default', notif: true },\n};\n\nexport const ActiveWithNotif: Story = {\n args: { state: 'active', notif: true },\n};\n\nexport const AllStates: Story = {\n render: () => (\n <View style={{ flexDirection: 'row', gap: 12, padding: 16 }}>\n <ButtonMenu state=\"default\" icon={<House />} />\n <ButtonMenu state=\"active\" icon={<MagnifyingGlass />} />\n <ButtonMenu state=\"disabled\" icon={<Gear />} />\n <ButtonMenu state=\"default\" icon={<Bell />} notif />\n <ButtonMenu state=\"active\" icon={<Bell />} notif />\n </View>\n ),\n};"]}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import type { Meta, StoryObj } from '@storybook/react-native';
|
|
2
|
-
import { type FilterChipProps } from './FilterChip';
|
|
3
|
-
type StoryArgs = FilterChipProps & {
|
|
4
|
-
colorScheme: 'light' | 'dark';
|
|
5
|
-
};
|
|
6
|
-
declare const meta: Meta<StoryArgs>;
|
|
7
|
-
export default meta;
|
|
8
|
-
type Story = StoryObj<StoryArgs>;
|
|
9
|
-
export declare const Default: Story;
|
|
10
|
-
export declare const Selected: Story;
|
|
11
|
-
export declare const Disabled: Story;
|
|
12
|
-
export declare const IconOnly: Story;
|
|
13
|
-
export declare const IconOnlySelected: Story;
|
|
14
|
-
export declare const AllStates: Story;
|
|
15
|
-
//# sourceMappingURL=FilterChip.stories.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"FilterChip.stories.d.ts","sourceRoot":"","sources":["../../../src/components/FilterChip/FilterChip.stories.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,yBAAyB,CAAC;AAG9D,OAAO,EAAc,KAAK,eAAe,EAAE,MAAM,cAAc,CAAC;AAEhE,KAAK,SAAS,GAAG,eAAe,GAAG;IAAE,WAAW,EAAE,OAAO,GAAG,MAAM,CAAA;CAAE,CAAC;AAErE,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,SAAS,CAyBzB,CAAC;AAEF,eAAe,IAAI,CAAC;AAEpB,KAAK,KAAK,GAAG,QAAQ,CAAC,SAAS,CAAC,CAAC;AAEjC,eAAO,MAAM,OAAO,EAAE,KAErB,CAAC;AAEF,eAAO,MAAM,QAAQ,EAAE,KAEtB,CAAC;AAEF,eAAO,MAAM,QAAQ,EAAE,KAEtB,CAAC;AAEF,eAAO,MAAM,QAAQ,EAAE,KAEtB,CAAC;AAEF,eAAO,MAAM,gBAAgB,EAAE,KAE9B,CAAC;AAEF,eAAO,MAAM,SAAS,EAAE,KAUvB,CAAC"}
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
/** Storybook stories for the FilterChip component */
|
|
2
|
-
import React from 'react';
|
|
3
|
-
import { View } from 'react-native';
|
|
4
|
-
import { Funnel, CaretDown, X, MagnifyingGlass } from 'phosphor-react-native';
|
|
5
|
-
import { FilterChip } from './FilterChip';
|
|
6
|
-
const meta = {
|
|
7
|
-
title: 'Components/FilterChip',
|
|
8
|
-
component: FilterChip,
|
|
9
|
-
render: ({ colorScheme: _colorScheme, ...args }) => (<FilterChip {...args}/>),
|
|
10
|
-
argTypes: {
|
|
11
|
-
colorScheme: {
|
|
12
|
-
control: { type: 'radio' },
|
|
13
|
-
options: ['light', 'dark'],
|
|
14
|
-
},
|
|
15
|
-
type: {
|
|
16
|
-
control: { type: 'radio' },
|
|
17
|
-
options: ['icon', 'icon-text'],
|
|
18
|
-
},
|
|
19
|
-
selected: { control: { type: 'boolean' } },
|
|
20
|
-
disabled: { control: { type: 'boolean' } },
|
|
21
|
-
},
|
|
22
|
-
args: {
|
|
23
|
-
colorScheme: 'light',
|
|
24
|
-
type: 'icon-text',
|
|
25
|
-
selected: false,
|
|
26
|
-
disabled: false,
|
|
27
|
-
label: 'Filtrer',
|
|
28
|
-
},
|
|
29
|
-
};
|
|
30
|
-
export default meta;
|
|
31
|
-
export const Default = {
|
|
32
|
-
args: { label: 'Filtrer', iconLeft: <Funnel />, iconRight: <CaretDown /> },
|
|
33
|
-
};
|
|
34
|
-
export const Selected = {
|
|
35
|
-
args: { label: 'Filtrer', iconLeft: <Funnel />, iconRight: <X />, selected: true },
|
|
36
|
-
};
|
|
37
|
-
export const Disabled = {
|
|
38
|
-
args: { label: 'Filtrer', iconLeft: <Funnel />, disabled: true },
|
|
39
|
-
};
|
|
40
|
-
export const IconOnly = {
|
|
41
|
-
args: { type: 'icon', iconLeft: <MagnifyingGlass /> },
|
|
42
|
-
};
|
|
43
|
-
export const IconOnlySelected = {
|
|
44
|
-
args: { type: 'icon', iconLeft: <Funnel />, selected: true },
|
|
45
|
-
};
|
|
46
|
-
export const AllStates = {
|
|
47
|
-
render: () => (<View style={{ flexDirection: 'row', gap: 8, padding: 16, flexWrap: 'wrap' }}>
|
|
48
|
-
<FilterChip label="Default" iconLeft={<Funnel />} iconRight={<CaretDown />}/>
|
|
49
|
-
<FilterChip label="Selected" iconLeft={<Funnel />} iconRight={<X />} selected/>
|
|
50
|
-
<FilterChip label="Disabled" iconLeft={<Funnel />} disabled/>
|
|
51
|
-
<FilterChip type="icon" iconLeft={<Funnel />}/>
|
|
52
|
-
<FilterChip type="icon" iconLeft={<Funnel />} selected/>
|
|
53
|
-
</View>),
|
|
54
|
-
};
|
|
55
|
-
//# sourceMappingURL=FilterChip.stories.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"FilterChip.stories.js","sourceRoot":"","sources":["../../../src/components/FilterChip/FilterChip.stories.tsx"],"names":[],"mappings":"AAAA,qDAAqD;AACrD,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AACpC,OAAO,EAAE,MAAM,EAAE,SAAS,EAAE,CAAC,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAC9E,OAAO,EAAE,UAAU,EAAwB,MAAM,cAAc,CAAC;AAIhE,MAAM,IAAI,GAAoB;IAC5B,KAAK,EAAE,uBAAuB;IAC9B,SAAS,EAAE,UAAU;IACrB,MAAM,EAAE,CAAC,EAAE,WAAW,EAAE,YAAY,EAAE,GAAG,IAAI,EAAE,EAAE,EAAE,CAAC,CAClD,CAAC,UAAU,CAAC,IAAI,IAAI,CAAC,EAAG,CACzB;IACD,QAAQ,EAAE;QACR,WAAW,EAAE;YACX,OAAO,EAAE,EAAE,IAAI,EAAE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\nimport type { Meta, StoryObj } from '@storybook/react-native';\nimport { View } from 'react-native';\nimport { Funnel, CaretDown, X, MagnifyingGlass } from 'phosphor-react-native';\nimport { FilterChip, type FilterChipProps } from './FilterChip';\n\ntype StoryArgs = FilterChipProps & { colorScheme: 'light' | 'dark' };\n\nconst meta: Meta<StoryArgs> = {\n title: 'Components/FilterChip',\n component: FilterChip,\n render: ({ colorScheme: _colorScheme, ...args }) => (\n <FilterChip {...args} />\n ),\n argTypes: {\n colorScheme: {\n control: { type: 'radio' },\n options: ['light', 'dark'],\n },\n type: {\n control: { type: 'radio' },\n options: ['icon', 'icon-text'],\n },\n selected: { control: { type: 'boolean' } },\n disabled: { control: { type: 'boolean' } },\n },\n args: {\n colorScheme: 'light',\n type: 'icon-text',\n selected: false,\n disabled: false,\n label: 'Filtrer',\n },\n};\n\nexport default meta;\n\ntype Story = StoryObj<StoryArgs>;\n\nexport const Default: Story = {\n args: { label: 'Filtrer', iconLeft: <Funnel />, iconRight: <CaretDown /> },\n};\n\nexport const Selected: Story = {\n args: { label: 'Filtrer', iconLeft: <Funnel />, iconRight: <X />, selected: true },\n};\n\nexport const Disabled: Story = {\n args: { label: 'Filtrer', iconLeft: <Funnel />, disabled: true },\n};\n\nexport const IconOnly: Story = {\n args: { type: 'icon', iconLeft: <MagnifyingGlass /> },\n};\n\nexport const IconOnlySelected: Story = {\n args: { type: 'icon', iconLeft: <Funnel />, selected: true },\n};\n\nexport const AllStates: Story = {\n render: () => (\n <View style={{ flexDirection: 'row', gap: 8, padding: 16, flexWrap: 'wrap' }}>\n <FilterChip label=\"Default\" iconLeft={<Funnel />} iconRight={<CaretDown />} />\n <FilterChip label=\"Selected\" iconLeft={<Funnel />} iconRight={<X />} selected />\n <FilterChip label=\"Disabled\" iconLeft={<Funnel />} disabled />\n <FilterChip type=\"icon\" iconLeft={<Funnel />} />\n <FilterChip type=\"icon\" iconLeft={<Funnel />} selected />\n </View>\n ),\n};"]}
|