@mekari/pixel3-theme 0.0.1 → 0.0.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.
@@ -0,0 +1,161 @@
1
+ import { defineSlotRecipe } from '@pandacss/dev'
2
+
3
+ const dropzoneSlotRecipe = defineSlotRecipe({
4
+ className: 'dropzone',
5
+ jsx: ['MpDropzone', 'mp-dropzone'],
6
+ slots: [
7
+ 'root',
8
+ 'wrapper',
9
+ 'box',
10
+ 'logoBox',
11
+ 'productBox',
12
+ 'avatarBox',
13
+ 'overlayWrapper',
14
+ 'overlay',
15
+ 'preview',
16
+ 'overlayPreview',
17
+ 'clearButton'
18
+ ],
19
+ base: {
20
+ root: {
21
+ position: 'relative',
22
+ width: 'full',
23
+ height: 'full'
24
+ },
25
+ wrapper: {
26
+ position: 'relative',
27
+ display: 'flex',
28
+ flexDirection: 'column',
29
+ justifyContent: 'center',
30
+ alignItems: 'center',
31
+ width: 'full',
32
+ height: 'inherit',
33
+ minHeight: 'inherit',
34
+ borderWidth: '1px',
35
+ borderColor: 'gray.100',
36
+ borderRadius: 'md',
37
+ borderStyle: 'dashed',
38
+ background: 'white',
39
+ outline: 'none',
40
+ transition: 'all 250ms',
41
+ _hover: {
42
+ borderColor: 'gray.400',
43
+ '& [data-overlay-preview=true]': {
44
+ display: 'flex'
45
+ }
46
+ },
47
+ _focusVisible: {
48
+ boxShadow: 'focus',
49
+ borderColor: 'blue.400',
50
+ _hover: {
51
+ borderColor: 'blue.400'
52
+ }
53
+ },
54
+ _disabled: {
55
+ cursor: 'not-allowed',
56
+ background: 'gray.50!'
57
+ },
58
+ _invalid: {
59
+ borderColor: 'red.400',
60
+ backgroundColor: 'red.50!',
61
+ _hover: {
62
+ borderColor: 'red.400!'
63
+ }
64
+ }
65
+ },
66
+ box: {
67
+ display: 'flex',
68
+ flexDirection: 'column',
69
+ alignItems: 'center',
70
+ justifyContent: 'center',
71
+ gap: '2'
72
+ },
73
+ logoBox: {
74
+ display: 'flex',
75
+ alignItems: 'center',
76
+ justifyContent: 'center',
77
+ gap: '2',
78
+ width: 'full',
79
+ height: 'full',
80
+ borderRadius: 'inherit',
81
+ cursor: 'pointer'
82
+ },
83
+ productBox: {
84
+ display: 'flex',
85
+ flexDirection: 'column',
86
+ alignItems: 'center',
87
+ justifyContent: 'center',
88
+ gap: '2',
89
+ width: 'full',
90
+ height: 'full',
91
+ borderRadius: 'inherit',
92
+ cursor: 'pointer'
93
+ },
94
+ avatarBox: {
95
+ display: 'flex',
96
+ alignItems: 'center',
97
+ justifyContent: 'center',
98
+ width: 'full',
99
+ height: 'full',
100
+ borderRadius: 'inherit',
101
+ cursor: 'pointer'
102
+ },
103
+ overlayWrapper: {
104
+ width: 'full',
105
+ height: 'inherit',
106
+ minHeight: 'inherit',
107
+ borderRadius: 'inherit'
108
+ },
109
+ overlay: {
110
+ position: 'absolute',
111
+ zIndex: '1',
112
+ display: 'flex',
113
+ flexDirection: 'column',
114
+ alignItems: 'center',
115
+ justifyContent: 'center',
116
+ gap: '2',
117
+ width: 'full',
118
+ height: 'full',
119
+ top: '0',
120
+ right: '0',
121
+ backdropFilter: 'blur(12px)',
122
+ borderRadius: 'md',
123
+ borderWidth: '1px',
124
+ borderColor: 'blue.400',
125
+ borderStyle: 'dashed'
126
+ },
127
+ preview: {
128
+ display: 'flex',
129
+ flexDirection: 'column',
130
+ alignItems: 'center',
131
+ justifyContent: 'center',
132
+ height: 'full',
133
+ borderRadius: 'inherit'
134
+ },
135
+ overlayPreview: {
136
+ display: 'none',
137
+ cursor: 'pointer',
138
+ position: 'absolute',
139
+ zIndex: '1',
140
+ width: 'full',
141
+ height: 'full',
142
+ background: 'overlay',
143
+ backdropFilter: 'blur(12px)',
144
+ borderRadius: 'inherit',
145
+ flexDirection: 'column',
146
+ justifyContent: 'center',
147
+ alignItems: 'center',
148
+ gap: '2'
149
+ },
150
+ clearButton: {
151
+ cursor: 'pointer',
152
+ position: 'absolute',
153
+ zIndex: '2',
154
+ background: 'white',
155
+ border: '2px solid white',
156
+ borderRadius: 'full',
157
+ }
158
+ }
159
+ })
160
+
161
+ export { dropzoneSlotRecipe }
@@ -21,6 +21,18 @@ import { progressSlotRecipe } from './progress'
21
21
  import { formControlSlotRecipe } from './form-control'
22
22
  import { inputTagSlotRecipe } from './input-tag'
23
23
  import { dividerRecipe } from './divider'
24
+ import { modalSlotRecipe } from './modal'
25
+ import { uploadSlotRecipe, uploadListSlotRecipe } from './upload'
26
+ import { dropzoneSlotRecipe } from './dropzone'
27
+
28
+ import {
29
+ bannerSlotRecipe,
30
+ bannerTitleRecipe,
31
+ bannerDescriptionRecipe,
32
+ bannerIconSlotRecipe,
33
+ bannerLinkRecipe,
34
+ bannerCloseButtonRecipe
35
+ } from './banner'
24
36
 
25
37
  export const recipes = {
26
38
  buttonRecipe,
@@ -39,7 +51,11 @@ export const recipes = {
39
51
  selectedBorderRecipe,
40
52
  tableRecipe,
41
53
  tableContainerRecipe,
42
- dividerRecipe
54
+ dividerRecipe,
55
+ bannerTitleRecipe,
56
+ bannerDescriptionRecipe,
57
+ bannerLinkRecipe,
58
+ bannerCloseButtonRecipe
43
59
  }
44
60
 
45
61
  export const slotRecipes = {
@@ -57,5 +73,11 @@ export const slotRecipes = {
57
73
  avatarGroupSlotRecipe,
58
74
  selectSlotRecipe,
59
75
  formControlSlotRecipe,
60
- inputTagSlotRecipe
76
+ inputTagSlotRecipe,
77
+ modalSlotRecipe,
78
+ uploadSlotRecipe,
79
+ uploadListSlotRecipe,
80
+ dropzoneSlotRecipe,
81
+ bannerSlotRecipe,
82
+ bannerIconSlotRecipe
61
83
  }
@@ -0,0 +1,108 @@
1
+ import { defineSlotRecipe } from '@pandacss/dev'
2
+
3
+ export const modalSlotRecipe = defineSlotRecipe({
4
+ className: 'modal',
5
+ description: 'The styles for the Modal component',
6
+ jsx: ['MpModal', 'mp-modal'],
7
+ slots: ['root', 'rootChild', 'body', 'contentRoot', 'contentChild', 'header', 'footer', 'body', 'overlay', 'closeButton'],
8
+ base: {
9
+ root: {
10
+ position: 'relative',
11
+ zIndex: 'modal'
12
+ },
13
+ rootChild: {
14
+ position: 'fixed',
15
+ top: 0,
16
+ right: 0,
17
+ bottom: 0,
18
+ left: 0
19
+ },
20
+ body: {
21
+ p: 4,
22
+ flex: 1,
23
+ },
24
+ contentRoot: {
25
+ pos: 'fixed',
26
+ left: '0',
27
+ w: '100%',
28
+ h: '100%',
29
+ zIndex: 'modal',
30
+ },
31
+ contentChild: {
32
+ outline: 0,
33
+ width: '100%',
34
+ position: 'relative',
35
+ display: 'flex',
36
+ flexDir: 'column',
37
+ zIndex: 'modal',
38
+ fontFamily: 'body',
39
+ borderColor: 'gray.100',
40
+ bg: 'white',
41
+ marginInline: 'auto',
42
+ },
43
+
44
+ header: {
45
+ px: 4,
46
+ py: 3,
47
+ position: 'relative',
48
+ fontSize: 'md',
49
+ fontWeight: 'semiBold',
50
+ bg: 'background',
51
+ borderTopLeftRadius: 'md',
52
+ borderTopRightRadius: 'md',
53
+ borderBottom: 'solid 1px',
54
+ borderBottomColor: 'gray.100'
55
+ },
56
+ closeButton: {
57
+ position: 'absolute',
58
+ top: '10px',
59
+ right: '12px',
60
+ bg: 'transparent',
61
+ borderColor: 'transparent'
62
+ },
63
+ footer: {
64
+ display: 'flex',
65
+ pt: 2,
66
+ px: 4,
67
+ pb: 4,
68
+ justifyContent: 'flex-end',
69
+ },
70
+ overlay: {
71
+ position: 'fixed',
72
+ bg: 'overlay',
73
+ left: '0',
74
+ top: '0',
75
+ w: '100vw',
76
+ h: '100vh',
77
+ zIndex: 'overlay',
78
+ }
79
+ },
80
+ variants: {
81
+ full: {
82
+ true: {
83
+ contentRoot: {
84
+ top: '0',
85
+ },
86
+ contentChild: {
87
+ height: '100vh',
88
+ border: 'none',
89
+ borderRadius: 'none'
90
+ }
91
+ },
92
+ false: {
93
+ contentRoot: {
94
+ top: '3.75rem',
95
+ },
96
+ contentChild: {
97
+ height: '100%',
98
+ borderWidth: '1px',
99
+ borderRadius: 'md'
100
+ }
101
+ }
102
+ }
103
+ },
104
+
105
+ defaultVariants: {
106
+ full: false
107
+ },
108
+ })
@@ -19,7 +19,7 @@ const tableRecipe = defineRecipe({
19
19
  }
20
20
  }
21
21
  },
22
- thead: {
22
+ '& > thead': {
23
23
  width: 'full',
24
24
  backgroundColor: 'gray.25',
25
25
  '&[data-table-head-fixed=true]': {
@@ -29,15 +29,15 @@ const tableRecipe = defineRecipe({
29
29
  boxShadow: '0px 2px var(--mp-colors-gray-100)'
30
30
  }
31
31
  },
32
- tbody: {
32
+ '& > tbody': {
33
33
  width: 'full'
34
34
  },
35
- tr: {
35
+ '& > tr': {
36
36
  width: 'full',
37
37
  boxSizing: 'border-box',
38
38
  whiteSpace: 'nowrap'
39
39
  },
40
- 'th, td': {
40
+ '& th, & td': {
41
41
  cursor: 'default',
42
42
  paddingLeft: '2',
43
43
  paddingRight: '4',
@@ -50,15 +50,15 @@ const tableRecipe = defineRecipe({
50
50
  borderColor: 'gray.100',
51
51
  transition: 'background linear 120ms'
52
52
  },
53
- th: {
53
+ '& th': {
54
54
  fontWeight: 'semiBold',
55
55
  backgroundColor: 'gray.25'
56
56
  },
57
- td: {
57
+ '& td': {
58
58
  fontWeight: 'regular',
59
59
  backgroundColor: 'white'
60
60
  },
61
- 'th[data-table-cell-fixed=true], td[data-table-cell-fixed=true]': {
61
+ '& th[data-table-cell-fixed=true], & td[data-table-cell-fixed=true]': {
62
62
  position: 'sticky',
63
63
  zIndex: 'docked',
64
64
  left: '0',
@@ -28,7 +28,6 @@ const tagSlotRecipe = defineSlotRecipe({
28
28
  close: {
29
29
  position: 'absolute!',
30
30
  color: 'gray.600',
31
- background: 'linear-gradient(270deg, #EDF0F2 75%, rgba(237, 240, 242, 0) 111.54%)!',
32
31
  border: 'none',
33
32
  right: '0',
34
33
  width: '5',
@@ -74,11 +73,19 @@ const tagSlotRecipe = defineSlotRecipe({
74
73
  }
75
74
  },
76
75
  compoundVariants: [
76
+ {
77
+ variant: 'gray',
78
+ css: {
79
+ close: {
80
+ background: 'linear-gradient(270deg, #EDF0F2 75%, rgba(237, 240, 242, 0) 111.54%)'
81
+ }
82
+ }
83
+ },
77
84
  {
78
85
  variant: 'red',
79
86
  css: {
80
87
  close: {
81
- background: 'linear-gradient(270deg, #FDECEE 75%, rgba(237, 240, 242, 0) 111.54%)!'
88
+ background: 'linear-gradient(270deg, #FDECEE 75%, rgba(237, 240, 242, 0) 111.54%)'
82
89
  }
83
90
  }
84
91
  },
@@ -0,0 +1,99 @@
1
+ import { defineSlotRecipe } from '@pandacss/dev'
2
+
3
+ const uploadSlotRecipe = defineSlotRecipe({
4
+ className: 'upload',
5
+ jsx: ['MpUpload', 'mp-upload'],
6
+ slots: ['root', 'resetButton'],
7
+ base: {
8
+ root: {
9
+ position: 'relative',
10
+ width: 'full',
11
+ display: 'flex',
12
+ alignItems: 'center',
13
+ gap: '3',
14
+ py: '1',
15
+ pl: '1',
16
+ pr: '3',
17
+ borderWidth: '1px',
18
+ borderColor: 'gray.100',
19
+ borderRadius: 'md',
20
+ backgroundColor: 'white',
21
+ outline: 'none',
22
+ transition: 'all 250ms',
23
+ _hover: {
24
+ borderColor: 'gray.400',
25
+ '& .mp-upload__resetButton': {
26
+ display: 'block'
27
+ }
28
+ },
29
+ _focusVisible: {
30
+ boxShadow: 'focus',
31
+ borderColor: 'blue.400',
32
+ _hover: {
33
+ borderColor: 'blue.400'
34
+ }
35
+ },
36
+ _disabled: {
37
+ cursor: 'not-allowed',
38
+ background: 'gray.50'
39
+ },
40
+ _invalid: {
41
+ borderColor: 'red.400',
42
+ _hover: {
43
+ borderColor: 'red.400'
44
+ }
45
+ }
46
+ },
47
+ resetButton: {
48
+ display: 'none',
49
+ cursor: 'pointer',
50
+ position: 'absolute',
51
+ top: '2',
52
+ right: '3'
53
+ }
54
+ }
55
+ })
56
+
57
+ const uploadListSlotRecipe = defineSlotRecipe({
58
+ className: 'upload-list',
59
+ jsx: ['MpUploadList', 'mp-upload-list'],
60
+ slots: ['root', 'titleWrapper', 'actionWrapper'],
61
+ base: {
62
+ root: {
63
+ position: 'relative',
64
+ width: 'full',
65
+ display: 'flex',
66
+ alignItems: 'center',
67
+ justifyContent: 'start',
68
+ gap: '3',
69
+ py: '2',
70
+ px: '1',
71
+ borderRadius: 'md',
72
+ backgroundColor: 'white',
73
+ transition: 'all 250ms',
74
+ _hover: {
75
+ backgroundColor: 'background'
76
+ }
77
+ },
78
+ titleWrapper: {
79
+ display: 'flex',
80
+ flexDirection: 'column',
81
+ minWidth: '1px',
82
+ },
83
+ actionWrapper: {
84
+ display: 'flex',
85
+ flexDirection: 'row',
86
+ gap: '0.5',
87
+ ml: 'auto',
88
+ '& > button': {
89
+ // Remove hover style for Button Icon
90
+ _hover: {
91
+ background: 'transparent!important',
92
+ borderColor: 'transparent!important'
93
+ }
94
+ }
95
+ }
96
+ }
97
+ })
98
+
99
+ export { uploadSlotRecipe, uploadListSlotRecipe }
@@ -27,6 +27,30 @@ export const colors = defineTokens.colors({
27
27
  talenta: { value: '#F22929', description: 'Mekari Talenta' },
28
28
  university: { value: '#448AFF', description: 'Mekari University' }
29
29
  },
30
+ whiteAlpha: {
31
+ 50: { value: 'rgba(255, 255, 255, 0.04)' },
32
+ 100: { value: 'rgba(255, 255, 255, 0.06)' },
33
+ 200: { value: 'rgba(255, 255, 255, 0.08)' },
34
+ 300: { value: 'rgba(255, 255, 255, 0.16)' },
35
+ 400: { value: 'rgba(255, 255, 255, 0.24)' },
36
+ 500: { value: 'rgba(255, 255, 255, 0.36)' },
37
+ 600: { value: 'rgba(255, 255, 255, 0.48)' },
38
+ 700: { value: 'rgba(255, 255, 255, 0.64)' },
39
+ 800: { value: 'rgba(255, 255, 255, 0.80)' },
40
+ 900: { value: 'rgba(255, 255, 255, 0.92)' }
41
+ },
42
+ blackAplpha: {
43
+ 50: { value: 'rgba(0, 0, 0, 0.04)' },
44
+ 100: { value: 'rgba(0, 0, 0, 0.06)' },
45
+ 200: { value: 'rgba(0, 0, 0, 0.08)' },
46
+ 300: { value: 'rgba(0, 0, 0, 0.16)' },
47
+ 400: { value: 'rgba(0, 0, 0, 0.24)' },
48
+ 500: { value: 'rgba(0, 0, 0, 0.36)' },
49
+ 600: { value: 'rgba(0, 0, 0, 0.48)' },
50
+ 700: { value: 'rgba(0, 0, 0, 0.64)' },
51
+ 800: { value: 'rgba(0, 0, 0, 0.80)' },
52
+ 900: { value: 'rgba(0, 0, 0, 0.92)' }
53
+ },
30
54
  gray: {
31
55
  25: {
32
56
  value: '#F8F9FB',
@@ -24,5 +24,6 @@ export const sizes = defineTokens.sizes({
24
24
  22: { value: '5.5rem', description: '96px' },
25
25
  56: { value: '14rem', description: '224px' },
26
26
  65: { value: '17.5rem', description: '280px' },
27
- full: { value: '100%' }
27
+ full: { value: '100%' },
28
+ sm: {value: '24rem'}
28
29
  })