cozy-ui 111.7.0 → 111.8.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 CHANGED
@@ -1,3 +1,10 @@
1
+ # [111.8.0](https://github.com/cozy/cozy-ui/compare/v111.7.0...v111.8.0) (2024-08-19)
2
+
3
+
4
+ ### Features
5
+
6
+ * **MobileStepper:** Add cozy design to MUI export ([d6728f8](https://github.com/cozy/cozy-ui/commit/d6728f8))
7
+
1
8
  # [111.7.0](https://github.com/cozy/cozy-ui/compare/v111.6.0...v111.7.0) (2024-08-14)
2
9
 
3
10
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cozy-ui",
3
- "version": "111.7.0",
3
+ "version": "111.8.0",
4
4
  "description": "Cozy apps UI SDK",
5
5
  "main": "./index.js",
6
6
  "bin": {
@@ -0,0 +1,43 @@
1
+ ```jsx
2
+ import { useState } from 'react'
3
+ import MobileStepper from 'cozy-ui/transpiled/react/MobileStepper'
4
+ import IconButton from 'cozy-ui/transpiled/react/IconButton'
5
+ import Icon from 'cozy-ui/transpiled/react/Icon'
6
+ import LeftIcon from 'cozy-ui/transpiled/react/Icons/Left'
7
+ import RightIcon from 'cozy-ui/transpiled/react/Icons/Right'
8
+
9
+ const maxSteps = 5
10
+ const [activeStep, setActiveStep] = useState(0)
11
+
12
+ const handleNext = () => {
13
+ setActiveStep(activeStep + 1)
14
+ }
15
+
16
+ const handleBack = () => {
17
+ setActiveStep(activeStep - 1)
18
+ }
19
+
20
+ ;
21
+
22
+ <div class="u-flex">
23
+ <MobileStepper
24
+ className="u-mh-auto"
25
+ steps={maxSteps}
26
+ position="static"
27
+ activeStep={activeStep}
28
+ nextButton={
29
+ <IconButton
30
+ onClick={handleNext}
31
+ disabled={activeStep === maxSteps - 1}
32
+ >
33
+ <Icon icon={RightIcon} />
34
+ </IconButton>
35
+ }
36
+ backButton={
37
+ <IconButton onClick={handleBack} disabled={activeStep === 0}>
38
+ <Icon icon={LeftIcon} />
39
+ </IconButton>
40
+ }
41
+ />
42
+ </div>
43
+ ```
@@ -876,5 +876,23 @@ export const makeLightNormalOverrides = theme => ({
876
876
  padding: '0 16px'
877
877
  }
878
878
  }
879
+ },
880
+ MuiMobileStepper: {
881
+ root: {
882
+ background: 'transparent',
883
+ height: 40,
884
+ padding: 0
885
+ },
886
+ dot: {
887
+ backgroundColor: 'transparent',
888
+ width: '10px',
889
+ height: '10px',
890
+ margin: '0 3px',
891
+ border: `1px solid ${theme.palette.border.main}`,
892
+ boxSizing: 'border-box'
893
+ },
894
+ dotActive: {
895
+ border: 'none'
896
+ }
879
897
  }
880
898
  })
@@ -1376,6 +1376,24 @@ export function makeDarkInvertedOverrides(theme: any): {
1376
1376
  };
1377
1377
  };
1378
1378
  };
1379
+ MuiMobileStepper: {
1380
+ root: {
1381
+ background: string;
1382
+ height: number;
1383
+ padding: number;
1384
+ };
1385
+ dot: {
1386
+ backgroundColor: string;
1387
+ width: string;
1388
+ height: string;
1389
+ margin: string;
1390
+ border: string;
1391
+ boxSizing: string;
1392
+ };
1393
+ dotActive: {
1394
+ border: string;
1395
+ };
1396
+ };
1379
1397
  } & {
1380
1398
  MuiLinearProgress: {
1381
1399
  colorPrimary: {
@@ -1376,4 +1376,22 @@ export function makeDarkNormalOverrides(theme: any): {
1376
1376
  };
1377
1377
  };
1378
1378
  };
1379
+ MuiMobileStepper: {
1380
+ root: {
1381
+ background: string;
1382
+ height: number;
1383
+ padding: number;
1384
+ };
1385
+ dot: {
1386
+ backgroundColor: string;
1387
+ width: string;
1388
+ height: string;
1389
+ margin: string;
1390
+ border: string;
1391
+ boxSizing: string;
1392
+ };
1393
+ dotActive: {
1394
+ border: string;
1395
+ };
1396
+ };
1379
1397
  };
@@ -1376,6 +1376,24 @@ export function makeLightInvertedOverrides(theme: any): {
1376
1376
  };
1377
1377
  };
1378
1378
  };
1379
+ MuiMobileStepper: {
1380
+ root: {
1381
+ background: string;
1382
+ height: number;
1383
+ padding: number;
1384
+ };
1385
+ dot: {
1386
+ backgroundColor: string;
1387
+ width: string;
1388
+ height: string;
1389
+ margin: string;
1390
+ border: string;
1391
+ boxSizing: string;
1392
+ };
1393
+ dotActive: {
1394
+ border: string;
1395
+ };
1396
+ };
1379
1397
  } & {
1380
1398
  MuiLinearProgress: {
1381
1399
  colorPrimary: {
@@ -1376,4 +1376,22 @@ export function makeLightNormalOverrides(theme: any): {
1376
1376
  };
1377
1377
  };
1378
1378
  };
1379
+ MuiMobileStepper: {
1380
+ root: {
1381
+ background: string;
1382
+ height: number;
1383
+ padding: number;
1384
+ };
1385
+ dot: {
1386
+ backgroundColor: string;
1387
+ width: string;
1388
+ height: string;
1389
+ margin: string;
1390
+ border: string;
1391
+ boxSizing: string;
1392
+ };
1393
+ dotActive: {
1394
+ border: string;
1395
+ };
1396
+ };
1379
1397
  };
@@ -820,6 +820,24 @@ export var makeLightNormalOverrides = function makeLightNormalOverrides(theme) {
820
820
  padding: '0 16px'
821
821
  }
822
822
  }
823
+ },
824
+ MuiMobileStepper: {
825
+ root: {
826
+ background: 'transparent',
827
+ height: 40,
828
+ padding: 0
829
+ },
830
+ dot: {
831
+ backgroundColor: 'transparent',
832
+ width: '10px',
833
+ height: '10px',
834
+ margin: '0 3px',
835
+ border: "1px solid ".concat(theme.palette.border.main),
836
+ boxSizing: 'border-box'
837
+ },
838
+ dotActive: {
839
+ border: 'none'
840
+ }
823
841
  }
824
842
  };
825
843
  };