@movable/ui 0.1.0 → 0.1.2

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.
@@ -14,31 +14,13 @@ jobs:
14
14
  steps:
15
15
  - uses: actions/checkout@v2
16
16
  with:
17
- fetch-depth: 0 # Necessary to generate changelog from commit history
18
- - uses: volta-cli/action@v1
19
-
17
+ fetch-depth: 0
20
18
  - name: git config
21
19
  run: |
22
20
  git config user.name "${GITHUB_ACTOR}"
23
21
  git config user.email "${GITHUB_ACTOR}@users.noreply.github.com"
24
-
25
- - name: Get yarn cache directory path
26
- id: yarn-cache-dir-path
27
- run: echo "::set-output name=dir::$(yarn config get cacheFolder)"
28
- - uses: actions/cache@v2
29
- with:
30
- path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
31
- key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
32
- restore-keys: |
33
- ${{ runner.os }}-yarn-
34
-
35
- - run: yarn install --immutable
36
-
37
- - name: Configure NPM with auth token
38
- run: npm config set //registry.npmjs.org/:_authToken $NPM_TOKEN
22
+ - run: npm install
23
+ - run: npm run release
39
24
  env:
40
25
  NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
41
-
42
- - run: yarn release ${{ github.event.inputs.increment }}
43
- env:
44
- GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
26
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
package/CHANGELOG.md CHANGED
@@ -1,10 +1,16 @@
1
1
 
2
2
 
3
- ## [0.1.0](https://github.com/movableink/ui/compare/0.1.0-alpha.1...0.1.0) (2023-09-19)
3
+ ## [0.1.2](https://github.com/movableink/ui/compare/0.1.1...0.1.2) (2023-10-18)
4
4
 
5
- ## [0.1.0-alpha.1](https://github.com/movableink/ui/compare/0.1.0-alpha.0...0.1.0-alpha.1) (2023-09-19)
6
5
 
6
+ ### Style
7
+
8
+ * add text field style overrides ([bdc5370](https://github.com/movableink/ui/commit/bdc5370f47b9c092a825ae78e297c6637d98de6b))
9
+
10
+ ## [0.1.1](https://github.com/movableink/ui/compare/0.1.0-alpha.1...0.1.1) (2023-10-13)
11
+
12
+ ## [0.1.0-alpha.1](https://github.com/movableink/ui/compare/0.1.0-alpha.0...0.1.0-alpha.1) (2023-09-19)
7
13
 
8
14
  ### Features
9
15
 
10
- * added theme from DV team ([d692875](https://github.com/movableink/ui/commit/d692875be6b3f7ffd6c018d50f77702d3f6a7626))
16
+ - added theme from DV team ([d692875](https://github.com/movableink/ui/commit/d692875be6b3f7ffd6c018d50f77702d3f6a7626))
package/README.md CHANGED
@@ -3,11 +3,32 @@
3
3
  This repo contains the shared components for our frontend applications. Using this [react component library guide](https://prateeksurana.me/blog/react-component-library-using-storybook-7/#compiling-the-library-using-rollup)
4
4
 
5
5
  ## Local Development
6
+
6
7
  ### Installation
7
8
 
8
9
  1. Ensure you have [`volta`](https://volta.sh) installed on your computer
9
10
  2. Clone the repo
10
- 3. `npm install`
11
+ 3. `npm install` (note: `npm`, not `yarn`)
12
+
13
+ ### Linking to local Studio
14
+
15
+ 1. `@movable/ui`: `npm run watch`
16
+
17
+ 2. `front-end/packages/studio` (after making the change below): `yarn`, then `yarn dev`, `yarn test:dev`, or similar
18
+
19
+ ```js
20
+ // front-end/packages/studio/package.json
21
+
22
+ {
23
+ // ...
24
+ "devDependencies": {
25
+ "@movable/ui": "link:./path/to/ui"
26
+ // ...
27
+ }
28
+ // ...
29
+ }
30
+ ```
31
+
11
32
  ## Conventional Commits
12
33
 
13
34
  This repo has [conventional-commits](https://www.conventionalcommits.org/en/v1.0.0/#summary) We lint for this both pre-commit and on PR actions. It is **required** and will not pass without it.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@movable/ui",
3
- "version": "0.1.0",
3
+ "version": "0.1.2",
4
4
  "description": "Movable Ink's shared MUI components and MUI theme for our vite applications",
5
5
  "main": "lib/index.js",
6
6
  "module": "lib/index.esm.js",
@@ -8,6 +8,7 @@
8
8
  "scripts": {
9
9
  "lint": "eslint src --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
10
10
  "build": "rollup -c",
11
+ "watch": "rollup -c -w",
11
12
  "release": "release-it",
12
13
  "prepare": "husky install"
13
14
  },
package/src/theme.ts CHANGED
@@ -2,10 +2,13 @@ import {
2
2
  blue,
3
3
  green,
4
4
  grey,
5
+ indigo,
5
6
  lightBlue,
7
+ lightGreen,
6
8
  orange,
7
9
  purple,
8
10
  red,
11
+ yellow,
9
12
  } from '@mui/material/colors';
10
13
  import { ThemeOptions, alpha, createTheme } from '@mui/material/styles';
11
14
 
@@ -15,6 +18,56 @@ declare module '@mui/material/styles' {
15
18
  }
16
19
  interface Palette {
17
20
  focusVisible: string;
21
+ blue50: string;
22
+ blue100: string;
23
+ blue200: string;
24
+ blue300: string;
25
+ blue400: string;
26
+ blue500: string;
27
+ blue600: string;
28
+ blue700: string;
29
+ blue800: string;
30
+ blue900: string;
31
+ indigo50: string;
32
+ indigo100: string;
33
+ indigo200: string;
34
+ indigo300: string;
35
+ indigo400: string;
36
+ indigo500: string;
37
+ indigo600: string;
38
+ indigo700: string;
39
+ indigo800: string;
40
+ indigo900: string;
41
+ green50: string;
42
+ green100: string;
43
+ green200: string;
44
+ green300: string;
45
+ green400: string;
46
+ green500: string;
47
+ green600: string;
48
+ green700: string;
49
+ green800: string;
50
+ green900: string;
51
+ lightBlue50: string;
52
+ lightBlue100: string;
53
+ lightBlue200: string;
54
+ lightBlue300: string;
55
+ lightBlue400: string;
56
+ lightBlue500: string;
57
+ lightBlue600: string;
58
+ lightBlue700: string;
59
+ lightBlue800: string;
60
+ lightBlue900: string;
61
+ lightGreen50: string;
62
+ lightGreen100: string;
63
+ lightGreen200: string;
64
+ lightGreen300: string;
65
+ lightGreen400: string;
66
+ lightGreen500: string;
67
+ lightGreen600: string;
68
+ lightGreen700: string;
69
+ lightGreen800: string;
70
+ lightGreen900: string;
18
71
  neutral50: string;
19
72
  neutral100: string;
20
73
  neutral200: string;
@@ -29,16 +82,36 @@ declare module '@mui/material/styles' {
29
82
  neutralA200: string;
30
83
  neutralA400: string;
31
84
  neutralA700: string;
32
- blue50: string;
33
- blue100: string;
34
- blue200: string;
35
- blue300: string;
36
- blue400: string;
37
- blue500: string;
38
- blue600: string;
39
- blue700: string;
40
- blue800: string;
41
- blue900: string;
85
+ orange50: string;
86
+ orange100: string;
87
+ orange200: string;
88
+ orange300: string;
89
+ orange400: string;
90
+ orange500: string;
91
+ orange600: string;
92
+ orange700: string;
93
+ orange800: string;
94
+ orange900: string;
95
+ purple50: string;
96
+ purple100: string;
97
+ purple200: string;
98
+ purple300: string;
99
+ purple400: string;
100
+ purple500: string;
101
+ purple600: string;
102
+ purple700: string;
103
+ purple800: string;
104
+ purple900: string;
105
+ yellow50: string;
106
+ yellow100: string;
107
+ yellow200: string;
108
+ yellow300: string;
109
+ yellow400: string;
110
+ yellow500: string;
111
+ yellow600: string;
112
+ yellow700: string;
113
+ yellow800: string;
114
+ yellow900: string;
42
115
  }
43
116
  interface PalletteOptions {
44
117
  focusVisible: string;
@@ -67,7 +140,51 @@ declare module '@mui/material/styles' {
67
140
 
68
141
  // TODO [Low]: put in /shared folder
69
142
  const theme = createTheme({
143
+ typography: {
144
+ fontFamily: ['Inter', 'Roboto', 'sans-serif'].join(','),
145
+ },
146
+
70
147
  components: {
148
+ MuiButton: {
149
+ styleOverrides: {
150
+ root: {
151
+ textTransform: 'capitalize',
152
+ },
153
+ textPrimary: {
154
+ color: blue[400],
155
+ },
156
+ outlinedInherit: {
157
+ borderColor: alpha(grey[900], 0.03),
158
+ },
159
+ },
160
+ },
161
+
162
+ MuiChip: {
163
+ styleOverrides: {
164
+ filledPrimary: {
165
+ backgroundColor: blue[50],
166
+ color: blue[900],
167
+ '.MuiChip-deleteIcon': {
168
+ color: blue[800],
169
+ '&:hover': {
170
+ color: blue[900],
171
+ },
172
+ '&:active': {
173
+ color: blue[900],
174
+ },
175
+ },
176
+ },
177
+ filledSuccess: {
178
+ backgroundColor: green[50],
179
+ color: green[900],
180
+ },
181
+ filledError: {
182
+ backgroundColor: red[50],
183
+ color: blue[900],
184
+ },
185
+ },
186
+ },
187
+
71
188
  MuiDataGrid: {
72
189
  styleOverrides: {
73
190
  root: {
@@ -89,20 +206,18 @@ const theme = createTheme({
89
206
  '.MuiDataGrid-toolbarContainer svg': {
90
207
  color: grey[700],
91
208
  },
209
+ '.MuiDataGrid-cell:focus': {
210
+ outline: 'none',
211
+ },
92
212
  },
93
213
  },
94
214
  },
95
215
 
96
- MuiButton: {
216
+ MuiLink: {
97
217
  styleOverrides: {
98
218
  root: {
99
- textTransform: 'capitalize',
100
- },
101
- textPrimary: {
102
219
  color: blue[400],
103
- },
104
- outlinedInherit: {
105
- borderColor: alpha(grey[900], 0.03),
220
+ textDecoration: 'none',
106
221
  },
107
222
  },
108
223
  },
@@ -124,42 +239,15 @@ const theme = createTheme({
124
239
  },
125
240
  styleOverrides: {
126
241
  root: {
127
- backgroundColor: grey[100],
128
- },
129
- },
130
- },
131
-
132
- MuiLink: {
133
- styleOverrides: {
134
- root: {
135
- color: blue[400],
136
- textDecoration: 'none',
137
- },
138
- },
139
- },
140
-
141
- MuiChip: {
142
- styleOverrides: {
143
- filledPrimary: {
144
- backgroundColor: blue[50],
145
- color: blue[900],
146
- '.MuiChip-deleteIcon': {
147
- color: blue[800],
148
- '&:hover': {
149
- color: blue[900],
150
- },
151
- '&:active': {
152
- color: blue[900],
153
- },
242
+ '.MuiInputBase-root': {
243
+ backgroundColor: grey[100],
244
+ },
245
+ '.MuiInputBase-input': {
246
+ backgroundColor: grey[100],
247
+ },
248
+ '.MuiFormHelperText-root': {
249
+ marginLeft: 0,
154
250
  },
155
- },
156
- filledSuccess: {
157
- backgroundColor: green[50],
158
- color: green[900],
159
- },
160
- filledError: {
161
- backgroundColor: red[50],
162
- color: blue[900],
163
251
  },
164
252
  },
165
253
  },
@@ -174,6 +262,61 @@ const theme = createTheme({
174
262
 
175
263
  focusVisible: alpha(blue[700], 0.3),
176
264
 
265
+ blue50: blue[50],
266
+ blue100: blue[100],
267
+ blue200: blue[200],
268
+ blue300: blue[300],
269
+ blue400: blue[400],
270
+ blue500: blue[500],
271
+ blue600: blue[600],
272
+ blue700: blue[700],
273
+ blue800: blue[800],
274
+ blue900: blue[900],
275
+
276
+ indigo50: indigo[50],
277
+ indigo100: indigo[100],
278
+ indigo200: indigo[200],
279
+ indigo300: indigo[300],
280
+ indigo400: indigo[400],
281
+ indigo500: indigo[500],
282
+ indigo600: indigo[600],
283
+ indigo700: indigo[700],
284
+ indigo800: indigo[800],
285
+ indigo900: indigo[900],
286
+
287
+ green50: green[50],
288
+ green100: green[100],
289
+ green200: green[200],
290
+ green300: green[300],
291
+ green400: green[400],
292
+ green500: green[500],
293
+ green600: green[600],
294
+ green700: green[700],
295
+ green800: green[800],
296
+ green900: green[900],
297
+
298
+ lightBlue50: lightBlue[50],
299
+ lightBlue100: lightBlue[100],
300
+ lightBlue200: lightBlue[200],
301
+ lightBlue300: lightBlue[300],
302
+ lightBlue400: lightBlue[400],
303
+ lightBlue500: lightBlue[500],
304
+ lightBlue600: lightBlue[600],
305
+ lightBlue700: lightBlue[700],
306
+ lightBlue800: lightBlue[800],
307
+ lightBlue900: lightBlue[900],
308
+
309
+ lightGreen50: lightGreen[50],
310
+ lightGreen100: lightGreen[100],
311
+ lightGreen200: lightGreen[200],
312
+ lightGreen300: lightGreen[300],
313
+ lightGreen400: lightGreen[400],
314
+ lightGreen500: lightGreen[500],
315
+ lightGreen600: lightGreen[600],
316
+ lightGreen700: lightGreen[700],
317
+ lightGreen800: lightGreen[800],
318
+ lightGreen900: lightGreen[900],
319
+
177
320
  neutral50: grey[50],
178
321
  neutral100: grey[100],
179
322
  neutral200: grey[200],
@@ -189,16 +332,38 @@ const theme = createTheme({
189
332
  neutralA400: grey['A400'],
190
333
  neutralA700: grey['A700'],
191
334
 
192
- blue50: blue[50],
193
- blue100: blue[100],
194
- blue200: blue[200],
195
- blue300: blue[300],
196
- blue400: blue[400],
197
- blue500: blue[500],
198
- blue600: blue[600],
199
- blue700: blue[700],
200
- blue800: blue[800],
201
- blue900: blue[900],
335
+ orange50: orange[50],
336
+ orange100: orange[100],
337
+ orange200: orange[200],
338
+ orange300: orange[300],
339
+ orange400: orange[400],
340
+ orange500: orange[500],
341
+ orange600: orange[600],
342
+ orange700: orange[700],
343
+ orange800: orange[800],
344
+ orange900: orange[900],
345
+
346
+ purple50: purple[50],
347
+ purple100: purple[100],
348
+ purple200: purple[200],
349
+ purple300: purple[300],
350
+ purple400: purple[400],
351
+ purple500: purple[500],
352
+ purple600: purple[600],
353
+ purple700: purple[700],
354
+ purple800: purple[800],
355
+ purple900: purple[900],
356
+
357
+ yellow50: yellow[50],
358
+ yellow100: yellow[100],
359
+ yellow200: yellow[200],
360
+ yellow300: yellow[300],
361
+ yellow400: yellow[400],
362
+ yellow500: yellow[500],
363
+ yellow600: yellow[600],
364
+ yellow700: yellow[700],
365
+ yellow800: yellow[800],
366
+ yellow900: yellow[900],
202
367
  // todo: add rest of colors. see https://www.figma.com/file/9yr8neepsdgLbiFADaR6M2/MI----Library-Base?type=design&node-id=477-93017&t=wf27RohUWMM0z3UH-0
203
368
 
204
369
  primary: {
@@ -249,4 +414,4 @@ const theme = createTheme({
249
414
  },
250
415
  } as ThemeOptions);
251
416
 
252
- export default theme;
417
+ export default theme;