Skip to content
This repository was archived by the owner on Sep 20, 2024. It is now read-only.

Commit 9d4ff1c

Browse files
Merge pull request #34 from chakra-ui/chore/upgrade-theme
Chore/upgrade theme
2 parents dbbc408 + 26f8649 commit 9d4ff1c

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+1031
-353
lines changed

_templates/generator/component/package.json.ejs.t

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ to: packages/<%=h.changeCase.paramCase(name)%>/package.json
2929
},
3030
"sideEffects": false,
3131
"scripts": {
32-
"build": "concurrently yarn:build:*",
32+
"build": "rimraf ./dist && concurrently yarn:build:*",
3333
"build:esm": "cross-env BABEL_ENV=esm babel src --root-mode upward --extensions .ts,.tsx -d dist/esm --source-maps",
3434
"build:cjs": "cross-env BABEL_ENV=cjs babel src --root-mode upward --extensions .ts,.tsx -d dist/cjs --source-maps",
3535
"build:types": "cross-env tsc --emitDeclarationOnly --declaration --declarationDir dist/types",

_templates/generator/module/package.json.ejs.t

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ to: packages/<%=h.changeCase.paramCase(name)%>/package.json
1717
"author": "Jonathan Bakebwa [email protected]",
1818
"license": "MIT",
1919
"scripts": {
20-
"build": "concurrently yarn:build:*",
20+
"build": "rimraf ./dist && concurrently yarn:build:*",
2121
"build:esm": "cross-env BABEL_ENV=esm babel src --root-mode upward --extensions .ts,.tsx -d dist/esm --source-maps",
2222
"build:cjs": "cross-env BABEL_ENV=cjs babel src --root-mode upward --extensions .ts,.tsx -d dist/cjs --source-maps",
2323
"watch": "concurrently yarn:watch:*",

packages/c-accordion/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"author": "Jonathan Bakebwa [email protected]",
1414
"license": "MIT",
1515
"scripts": {
16-
"build": "concurrently yarn:build:*",
16+
"build": "rimraf ./dist && concurrently yarn:build:*",
1717
"build:esm": "cross-env BABEL_ENV=esm babel src --root-mode upward --extensions .ts,.tsx -d dist/esm --source-maps",
1818
"build:cjs": "cross-env BABEL_ENV=cjs babel src --root-mode upward --extensions .ts,.tsx -d dist/cjs --source-maps",
1919
"build:types": "cross-env tsc --emitDeclarationOnly --declaration --declarationDir dist/types"

packages/c-alert/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"author": "Jonathan Bakebwa [email protected]",
1414
"license": "MIT",
1515
"scripts": {
16-
"build": "concurrently yarn:build:*",
16+
"build": "rimraf ./dist && concurrently yarn:build:*",
1717
"build:esm": "cross-env BABEL_ENV=esm babel src --root-mode upward --extensions .ts,.tsx -d dist/esm --source-maps",
1818
"build:cjs": "cross-env BABEL_ENV=cjs babel src --root-mode upward --extensions .ts,.tsx -d dist/cjs --source-maps",
1919
"build:types": "cross-env tsc --emitDeclarationOnly --declaration --declarationDir dist/types",

packages/c-alert/src/alert.ts

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,31 @@
11
import { h, defineComponent, PropType, computed } from 'vue'
22
import {
33
chakra,
4-
ColorScheme,
5-
DeepComponentThemeConfig,
64
ThemingProps,
75
useMultiStyleConfig,
86
useStyles,
97
StylesProvider,
108
DOMElements,
9+
SystemStyleObject,
1110
} from '@chakra-ui/vue-system'
12-
import { SystemStyleObject } from '@chakra-ui/vue-system'
1311
import { createContext } from '@chakra-ui/vue-utils'
1412
import { CIcon } from '@chakra-ui/c-icon'
1513

1614
const STATUSES = {
1715
info: {
18-
colorScheme: 'blue' as ColorScheme,
16+
colorScheme: 'blue',
1917
icon: 'info',
2018
},
2119
success: {
22-
colorScheme: 'green' as ColorScheme,
20+
colorScheme: 'green',
2321
icon: 'check-circle',
2422
},
2523
warning: {
26-
colorScheme: 'orange' as ColorScheme,
24+
colorScheme: 'orange',
2725
icon: 'warning-alt',
2826
},
2927
error: {
30-
colorScheme: 'red' as ColorScheme,
28+
colorScheme: 'red',
3129
icon: 'warning',
3230
},
3331
}
@@ -63,18 +61,18 @@ export const CAlert = defineComponent({
6361
default: 'info',
6462
},
6563
colorScheme: {
66-
type: [String] as PropType<ColorScheme>,
64+
type: [String] as PropType<string>,
6765
},
6866
styleConfig: {
69-
type: [Object] as PropType<DeepComponentThemeConfig>,
67+
type: [Object] as PropType<any>,
7068
},
7169
variant: {
7270
type: [String] as PropType<AlertVariant>,
7371
default: 'solid',
7472
},
7573
},
7674
setup(props, { slots, attrs }) {
77-
const colorScheme: ColorScheme =
75+
const colorScheme: string =
7876
props.colorScheme || STATUSES[props.status].colorScheme
7977

8078
const themingProps: ThemingProps = {

packages/c-badge/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
},
2626
"sideEffects": false,
2727
"scripts": {
28-
"build": "concurrently yarn:build:*",
28+
"build": "rimraf ./dist && concurrently yarn:build:*",
2929
"build:esm": "cross-env BABEL_ENV=esm babel src --root-mode upward --extensions .ts,.tsx -d dist/esm --source-maps",
3030
"build:cjs": "cross-env BABEL_ENV=cjs babel src --root-mode upward --extensions .ts,.tsx -d dist/cjs --source-maps",
3131
"build:types": "cross-env tsc --emitDeclarationOnly --declaration --declarationDir dist/types",

packages/c-button/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"author": "Jonathan Bakebwa [email protected]",
1414
"license": "MIT",
1515
"scripts": {
16-
"build": "concurrently yarn:build:*",
16+
"build": "rimraf ./dist && concurrently yarn:build:*",
1717
"build:esm": "cross-env BABEL_ENV=esm babel src --root-mode upward --extensions .ts,.tsx,.tsx -d dist/esm --source-maps",
1818
"build:cjs": "cross-env BABEL_ENV=cjs babel src --root-mode upward --extensions .ts,.tsx,.tsx -d dist/cjs --source-maps",
1919
"build:types": "cross-env tsc --emitDeclarationOnly --declaration --declarationDir dist/types",

packages/c-button/src/button-group.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import {
44
SystemStyleObject,
55
} from '@chakra-ui/styled-system'
66
import { chakra, ThemingProps } from '@chakra-ui/vue-system'
7-
import { ComponentThemeConfig } from '@chakra-ui/vue-theme'
87
import { createContext } from '@chakra-ui/vue-utils'
98

109
export interface ButtonGroupProps extends ThemingProps {
@@ -41,7 +40,7 @@ const props = {
4140
default: 'sm',
4241
},
4342
colorScheme: String as PropType<string>,
44-
styleConfig: String as PropType<ComponentThemeConfig>,
43+
styleConfig: String as PropType<any>,
4544
}
4645

4746
type ButtonGroupContext = () => ThemingProps & {

packages/c-button/src/button.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { defineComponent, PropType, computed, cloneVNode, h } from 'vue'
1+
import { defineComponent, PropType, computed, h } from 'vue'
22
import {
33
chakra,
44
useStyleConfig,

packages/c-color-mode/package.json

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
{
2+
"name": "@chakra-ui/c-color-mode",
3+
"version": "1.0.0",
4+
"main": "dist/cjs/index.js",
5+
"module": "dist/esm/index.js",
6+
"types": "dist/types/index.d.ts",
7+
"typings": "dist/types/index.d.ts",
8+
"author": "Jonathan Bakebwa <[email protected]>",
9+
"homepage": "https://github.com/chakra-ui/chakra-ui-vue-next#readme",
10+
"license": "MIT",
11+
"files": [
12+
"dist"
13+
],
14+
15+
"publishConfig": {
16+
"access": "public"
17+
},
18+
"repository": {
19+
"type": "git",
20+
"url": "git+https://github.com/chakra-ui/chakra-ui-vue-next.git"
21+
},
22+
"bugs": {
23+
"url": "https://github.com/chakra-ui/chakra-ui=vue-next/issues"
24+
},
25+
"sideEffects": false,
26+
"scripts": {
27+
"build": "rimraf ./dist && concurrently yarn:build:*",
28+
"build:esm": "cross-env BABEL_ENV=esm babel src --root-mode upward --extensions .ts,.tsx -d dist/esm --source-maps",
29+
"build:cjs": "cross-env BABEL_ENV=cjs babel src --root-mode upward --extensions .ts,.tsx -d dist/cjs --source-maps",
30+
"build:types": "cross-env tsc --emitDeclarationOnly --declaration --declarationDir dist/types",
31+
"watch": "concurrently yarn:watch:*",
32+
"watch:esm": "cross-env BABEL_ENV=esm babel src --root-mode upward --extensions .ts,.tsx -d dist/esm --source-maps --watch",
33+
"watch:cjs": "cross-env BABEL_ENV=cjs babel src --root-mode upward --extensions .ts,.tsx -d dist/cjs --source-maps --watch",
34+
"watch:types": "cross-env tsc --emitDeclarationOnly --declaration --declarationDir dist/types --watch"
35+
},
36+
"dependencies": {
37+
"@chakra-ui/vue-utils": "*"
38+
},
39+
"peerDependencies": {
40+
"vue": ">=3.0.5"
41+
}
42+
}

0 commit comments

Comments
 (0)