@kivid/native-components 1.0.0-alpha.20 → 1.0.0-alpha.22
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/dist/commonjs/components/ChatBubble/assets/class-variants.js +55 -4
- package/dist/commonjs/components/ChatBubble/assets/class-variants.js.map +1 -1
- package/dist/commonjs/components/ChatBubble/components/ChatBubbleEar/index.js +25 -20
- package/dist/commonjs/components/ChatBubble/components/ChatBubbleEar/index.js.map +1 -1
- package/dist/commonjs/components/ChatBubble/components/ChatBubbleEar/types.js +6 -0
- package/dist/commonjs/components/ChatBubble/components/ChatBubbleEar/types.js.map +1 -0
- package/dist/commonjs/components/ChatBubble/components/ChatBubbleText/index.js +8 -3
- package/dist/commonjs/components/ChatBubble/components/ChatBubbleText/index.js.map +1 -1
- package/dist/commonjs/components/ChatBubble/components/ChatBubbleTime/index.js +7 -1
- package/dist/commonjs/components/ChatBubble/components/ChatBubbleTime/index.js.map +1 -1
- package/dist/commonjs/components/ChatBubble/index.js +58 -13
- package/dist/commonjs/components/ChatBubble/index.js.map +1 -1
- package/dist/commonjs/components/DatePicker/assets/theme.js +99 -0
- package/dist/commonjs/components/DatePicker/assets/theme.js.map +1 -0
- package/dist/commonjs/components/DatePicker/index.js +174 -0
- package/dist/commonjs/components/DatePicker/index.js.map +1 -0
- package/dist/commonjs/components/DatePicker/types.js +6 -0
- package/dist/commonjs/components/DatePicker/types.js.map +1 -0
- package/dist/commonjs/components/IconButton/index.js +1 -0
- package/dist/commonjs/components/IconButton/index.js.map +1 -1
- package/dist/commonjs/components/MessageInput/assets/class-variants.js +31 -0
- package/dist/commonjs/components/MessageInput/assets/class-variants.js.map +1 -0
- package/dist/commonjs/components/MessageInput/index.js +105 -0
- package/dist/commonjs/components/MessageInput/index.js.map +1 -0
- package/dist/commonjs/components/MessageInput/types.js +6 -0
- package/dist/commonjs/components/MessageInput/types.js.map +1 -0
- package/dist/commonjs/components/TextInput/assets/class-variants.js +21 -4
- package/dist/commonjs/components/TextInput/assets/class-variants.js.map +1 -1
- package/dist/commonjs/components/TextInput/enums.js +7 -1
- package/dist/commonjs/components/TextInput/enums.js.map +1 -1
- package/dist/commonjs/components/TextInput/index.js +13 -3
- package/dist/commonjs/components/TextInput/index.js.map +1 -1
- package/dist/commonjs/components/index.js +65 -43
- package/dist/commonjs/components/index.js.map +1 -1
- package/dist/module/components/ChatBubble/assets/class-variants.js +54 -3
- package/dist/module/components/ChatBubble/assets/class-variants.js.map +1 -1
- package/dist/module/components/ChatBubble/components/ChatBubbleEar/index.js +26 -21
- package/dist/module/components/ChatBubble/components/ChatBubbleEar/index.js.map +1 -1
- package/dist/module/components/ChatBubble/components/ChatBubbleEar/types.js +4 -0
- package/dist/module/components/ChatBubble/components/ChatBubbleEar/types.js.map +1 -0
- package/dist/module/components/ChatBubble/components/ChatBubbleText/index.js +7 -2
- package/dist/module/components/ChatBubble/components/ChatBubbleText/index.js.map +1 -1
- package/dist/module/components/ChatBubble/components/ChatBubbleTime/index.js +9 -2
- package/dist/module/components/ChatBubble/components/ChatBubbleTime/index.js.map +1 -1
- package/dist/module/components/ChatBubble/index.js +59 -14
- package/dist/module/components/ChatBubble/index.js.map +1 -1
- package/dist/module/components/DatePicker/assets/theme.js +95 -0
- package/dist/module/components/DatePicker/assets/theme.js.map +1 -0
- package/dist/module/components/DatePicker/index.js +169 -0
- package/dist/module/components/DatePicker/index.js.map +1 -0
- package/dist/module/components/DatePicker/types.js +4 -0
- package/dist/module/components/DatePicker/types.js.map +1 -0
- package/dist/module/components/IconButton/index.js +1 -0
- package/dist/module/components/IconButton/index.js.map +1 -1
- package/dist/module/components/MessageInput/assets/class-variants.js +27 -0
- package/dist/module/components/MessageInput/assets/class-variants.js.map +1 -0
- package/dist/module/components/MessageInput/index.js +100 -0
- package/dist/module/components/MessageInput/index.js.map +1 -0
- package/dist/module/components/MessageInput/types.js +4 -0
- package/dist/module/components/MessageInput/types.js.map +1 -0
- package/dist/module/components/TextInput/assets/class-variants.js +21 -4
- package/dist/module/components/TextInput/assets/class-variants.js.map +1 -1
- package/dist/module/components/TextInput/enums.js +6 -0
- package/dist/module/components/TextInput/enums.js.map +1 -1
- package/dist/module/components/TextInput/index.js +14 -4
- package/dist/module/components/TextInput/index.js.map +1 -1
- package/dist/module/components/index.js +3 -0
- package/dist/module/components/index.js.map +1 -1
- package/dist/typescript/components/ChatBubble/assets/class-variants.d.ts +7 -1
- package/dist/typescript/components/ChatBubble/components/ChatBubbleEar/index.d.ts +1 -6
- package/dist/typescript/components/ChatBubble/components/ChatBubbleEar/types.d.ts +6 -0
- package/dist/typescript/components/ChatBubble/contexts/ChatBubbleContext/types.d.ts +1 -0
- package/dist/typescript/components/ChatBubble/types.d.ts +1 -0
- package/dist/typescript/components/DatePicker/assets/theme.d.ts +92 -0
- package/dist/typescript/components/DatePicker/index.d.ts +2 -0
- package/dist/typescript/components/DatePicker/types.d.ts +17 -0
- package/dist/typescript/components/MessageInput/assets/class-variants.d.ts +7 -0
- package/dist/typescript/components/MessageInput/index.d.ts +6 -0
- package/dist/typescript/components/MessageInput/types.d.ts +13 -0
- package/dist/typescript/components/TextInput/assets/class-variants.d.ts +3 -0
- package/dist/typescript/components/TextInput/enums.d.ts +5 -0
- package/dist/typescript/components/TextInput/index.d.ts +1 -1
- package/dist/typescript/components/TextInput/types.d.ts +4 -1
- package/dist/typescript/components/index.d.ts +6 -0
- package/package.json +26 -11
- package/src/components/ChatBubble/assets/class-variants.ts +130 -66
- package/src/components/ChatBubble/components/ChatBubbleEar/index.tsx +35 -24
- package/src/components/ChatBubble/components/ChatBubbleEar/types.ts +7 -0
- package/src/components/ChatBubble/components/ChatBubbleText/index.tsx +8 -5
- package/src/components/ChatBubble/components/ChatBubbleTime/index.tsx +4 -1
- package/src/components/ChatBubble/contexts/ChatBubbleContext/types.ts +1 -0
- package/src/components/ChatBubble/index.tsx +83 -23
- package/src/components/ChatBubble/types.ts +1 -0
- package/src/components/DatePicker/assets/theme.ts +92 -0
- package/src/components/DatePicker/index.tsx +203 -0
- package/src/components/DatePicker/types.ts +20 -0
- package/src/components/IconButton/index.tsx +1 -0
- package/src/components/MessageInput/assets/class-variants.ts +35 -0
- package/src/components/MessageInput/index.tsx +121 -0
- package/src/components/MessageInput/types.ts +18 -0
- package/src/components/TextInput/assets/class-variants.ts +32 -13
- package/src/components/TextInput/enums.ts +6 -0
- package/src/components/TextInput/index.tsx +9 -1
- package/src/components/TextInput/types.ts +4 -1
- package/src/components/index.ts +8 -0
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.chatBubbleTimeVariants = exports.chatBubbleBoxVariants = void 0;
|
|
6
|
+
exports.chatBubbleTimeVariants = exports.chatBubbleContainerVariants = exports.chatBubbleBoxVariants = void 0;
|
|
7
7
|
var _classVarianceAuthority = require("class-variance-authority");
|
|
8
|
-
const chatBubbleBoxVariants = exports.chatBubbleBoxVariants = (0, _classVarianceAuthority.cva)("gap-400 px-600 py-500 min-h-1000", {
|
|
8
|
+
const chatBubbleBoxVariants = exports.chatBubbleBoxVariants = (0, _classVarianceAuthority.cva)("gap-400 px-600 py-500 min-h-1000 shrink min-w-0", {
|
|
9
9
|
variants: {
|
|
10
10
|
variant: {
|
|
11
11
|
check: "",
|
|
@@ -28,6 +28,10 @@ const chatBubbleBoxVariants = exports.chatBubbleBoxVariants = (0, _classVariance
|
|
|
28
28
|
fullWidth: {
|
|
29
29
|
true: "flex-row w-full",
|
|
30
30
|
false: "flex-row"
|
|
31
|
+
},
|
|
32
|
+
origin: {
|
|
33
|
+
assistant: "",
|
|
34
|
+
user: ""
|
|
31
35
|
}
|
|
32
36
|
},
|
|
33
37
|
compoundVariants: [{
|
|
@@ -55,19 +59,66 @@ const chatBubbleBoxVariants = exports.chatBubbleBoxVariants = (0, _classVariance
|
|
|
55
59
|
className: "bg-chia-100"
|
|
56
60
|
}, {
|
|
57
61
|
hasEar: true,
|
|
62
|
+
origin: "assistant",
|
|
58
63
|
className: "rounded-700 rounded-bl-100"
|
|
59
64
|
}, {
|
|
60
65
|
hasEar: false,
|
|
66
|
+
origin: "assistant",
|
|
61
67
|
className: "rounded-700 rounded-bl-300"
|
|
68
|
+
}, {
|
|
69
|
+
hasEar: true,
|
|
70
|
+
origin: "user",
|
|
71
|
+
className: "rounded-700 rounded-br-100"
|
|
72
|
+
}, {
|
|
73
|
+
hasEar: false,
|
|
74
|
+
origin: "user",
|
|
75
|
+
className: "rounded-700 rounded-br-300"
|
|
62
76
|
}, {
|
|
63
77
|
messageType: "followUp",
|
|
78
|
+
origin: "assistant",
|
|
64
79
|
className: "rounded-tl-300"
|
|
80
|
+
}, {
|
|
81
|
+
messageType: "followUp",
|
|
82
|
+
origin: "user",
|
|
83
|
+
className: "rounded-tr-300"
|
|
84
|
+
}, {
|
|
85
|
+
origin: "user",
|
|
86
|
+
variant: "custom",
|
|
87
|
+
colorState: "fill",
|
|
88
|
+
className: "bg-grape-500"
|
|
89
|
+
}, {
|
|
90
|
+
origin: "user",
|
|
91
|
+
variant: "custom",
|
|
92
|
+
colorState: "outline",
|
|
93
|
+
className: ""
|
|
65
94
|
}],
|
|
66
95
|
defaultVariants: {
|
|
67
96
|
colorState: "fill",
|
|
68
97
|
messageType: "initial",
|
|
69
|
-
fullWidth: false
|
|
98
|
+
fullWidth: false,
|
|
99
|
+
origin: "assistant"
|
|
100
|
+
}
|
|
101
|
+
});
|
|
102
|
+
const chatBubbleTimeVariants = exports.chatBubbleTimeVariants = (0, _classVarianceAuthority.cva)("flex-row items-center gap-400 pt-400", {
|
|
103
|
+
variants: {
|
|
104
|
+
origin: {
|
|
105
|
+
assistant: "pl-400",
|
|
106
|
+
user: "pr-400"
|
|
107
|
+
}
|
|
108
|
+
},
|
|
109
|
+
defaultVariants: {
|
|
110
|
+
origin: "assistant"
|
|
111
|
+
}
|
|
112
|
+
});
|
|
113
|
+
const chatBubbleContainerVariants = exports.chatBubbleContainerVariants = (0, _classVarianceAuthority.cva)("flex", {
|
|
114
|
+
variants: {
|
|
115
|
+
origin: {
|
|
116
|
+
assistant: "items-start",
|
|
117
|
+
user: "items-end"
|
|
118
|
+
}
|
|
119
|
+
},
|
|
120
|
+
defaultVariants: {
|
|
121
|
+
origin: "assistant"
|
|
70
122
|
}
|
|
71
123
|
});
|
|
72
|
-
const chatBubbleTimeVariants = exports.chatBubbleTimeVariants = (0, _classVarianceAuthority.cva)("flex-row items-center gap-400 pt-400 pl-400");
|
|
73
124
|
//# sourceMappingURL=class-variants.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_classVarianceAuthority","require","chatBubbleBoxVariants","exports","cva","variants","variant","check","alert","error","custom","colorState","fill","outline","hasEar","true","false","messageType","initial","followUp","fullWidth","compoundVariants","className","defaultVariants","chatBubbleTimeVariants"],"sourceRoot":"../../../../../src","sources":["components/ChatBubble/assets/class-variants.ts"],"mappings":";;;;;;AAAA,IAAAA,uBAAA,GAAAC,OAAA;AAEO,MAAMC,qBAAqB,GAAAC,OAAA,CAAAD,qBAAA,GAAG,IAAAE,2BAAG,
|
|
1
|
+
{"version":3,"names":["_classVarianceAuthority","require","chatBubbleBoxVariants","exports","cva","variants","variant","check","alert","error","custom","colorState","fill","outline","hasEar","true","false","messageType","initial","followUp","fullWidth","origin","assistant","user","compoundVariants","className","defaultVariants","chatBubbleTimeVariants","chatBubbleContainerVariants"],"sourceRoot":"../../../../../src","sources":["components/ChatBubble/assets/class-variants.ts"],"mappings":";;;;;;AAAA,IAAAA,uBAAA,GAAAC,OAAA;AAEO,MAAMC,qBAAqB,GAAAC,OAAA,CAAAD,qBAAA,GAAG,IAAAE,2BAAG,EACtC,iDAAiD,EACjD;EACEC,QAAQ,EAAE;IACRC,OAAO,EAAE;MACPC,KAAK,EAAE,EAAE;MACTC,KAAK,EAAE,EAAE;MACTC,KAAK,EAAE,EAAE;MACTC,MAAM,EAAE;IACV,CAAC;IACDC,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,MAAM,EAAE,WAAW;IACnBI,SAAS,EAAE;EACb,CAAC,EACD;IACER,WAAW,EAAE,UAAU;IACvBI,MAAM,EAAE,MAAM;IACdI,SAAS,EAAE;EACb,CAAC,EACD;IACEJ,MAAM,EAAE,MAAM;IACdf,OAAO,EAAE,QAAQ;IACjBK,UAAU,EAAE,MAAM;IAClBc,SAAS,EAAE;EACb,CAAC,EACD;IACEJ,MAAM,EAAE,MAAM;IACdf,OAAO,EAAE,QAAQ;IACjBK,UAAU,EAAE,SAAS;IACrBc,SAAS,EAAE;EACb,CAAC,CACF;EACDC,eAAe,EAAE;IACff,UAAU,EAAE,MAAM;IAClBM,WAAW,EAAE,SAAS;IACtBG,SAAS,EAAE,KAAK;IAChBC,MAAM,EAAE;EACV;AACF,CACF,CAAC;AAEM,MAAMM,sBAAsB,GAAAxB,OAAA,CAAAwB,sBAAA,GAAG,IAAAvB,2BAAG,EACvC,sCAAsC,EACtC;EACEC,QAAQ,EAAE;IACRgB,MAAM,EAAE;MACNC,SAAS,EAAE,QAAQ;MACnBC,IAAI,EAAE;IACR;EACF,CAAC;EACDG,eAAe,EAAE;IACfL,MAAM,EAAE;EACV;AACF,CACF,CAAC;AAEM,MAAMO,2BAA2B,GAAAzB,OAAA,CAAAyB,2BAAA,GAAG,IAAAxB,2BAAG,EAAC,MAAM,EAAE;EACrDC,QAAQ,EAAE;IACRgB,MAAM,EAAE;MACNC,SAAS,EAAE,aAAa;MACxBC,IAAI,EAAE;IACR;EACF,CAAC;EACDG,eAAe,EAAE;IACfL,MAAM,EAAE;EACV;AACF,CAAC,CAAC","ignoreList":[]}
|
|
@@ -12,24 +12,29 @@ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e
|
|
|
12
12
|
const ChatBubbleEar = ({
|
|
13
13
|
type = "fill",
|
|
14
14
|
color = "#F2F7F7",
|
|
15
|
+
mirrored = false,
|
|
15
16
|
...props
|
|
16
17
|
}) => {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
})
|
|
18
|
+
const transform = mirrored ? [{
|
|
19
|
+
scaleX: -1
|
|
20
|
+
}] : undefined;
|
|
21
|
+
function renderSvgContent() {
|
|
22
|
+
if (type === "outline") {
|
|
23
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
|
|
24
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeSvg.Path, {
|
|
25
|
+
d: "M11.5 0.5V9.5H7.75098C2.95557 9.34303 1.06326 5.41102 0.511719 3.91016C0.476256 3.80748 0.523736 3.72138 0.575195 3.69141L0.576172 3.69043C0.597192 3.67831 0.616459 3.67593 0.632812 3.67773C0.649308 3.67957 0.669032 3.68628 0.688477 3.7041C1.18665 4.17051 2.2435 4.93738 3.79004 4.9375C6.23009 4.9375 8.23446 2.96737 8.47559 0.5H11.5Z",
|
|
26
|
+
fill: color,
|
|
27
|
+
stroke: "#DEE7E7",
|
|
28
|
+
strokeMiterlimit: 10
|
|
29
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeSvg.Path, {
|
|
30
|
+
d: "M8 3.15144V9H12V0H9C9 1.47424 8.5 2.46333 8 3.15144Z",
|
|
31
|
+
fill: color
|
|
32
|
+
})]
|
|
33
|
+
});
|
|
34
|
+
}
|
|
35
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeSvg.Path, {
|
|
36
|
+
d: "M12 10V3.55405e-05L8 0C8 2.4436 6.09369 4.43749 3.79039 4.43749C2.41431 4.43749 1.47239 3.75438 1.02718 3.3367C0.832174 3.15714 0.552541 3.12591 0.324419 3.25863C0.0484661 3.41867 -0.0692741 3.76609 0.0411073 4.07837C0.604052 5.61245 2.60563 9.83215 7.73469 10H12Z",
|
|
37
|
+
fill: color
|
|
33
38
|
});
|
|
34
39
|
}
|
|
35
40
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeSvg.default, {
|
|
@@ -37,11 +42,11 @@ const ChatBubbleEar = ({
|
|
|
37
42
|
height: 10,
|
|
38
43
|
viewBox: "0 0 12 10",
|
|
39
44
|
fill: "none",
|
|
45
|
+
style: {
|
|
46
|
+
transform
|
|
47
|
+
},
|
|
40
48
|
...props,
|
|
41
|
-
children:
|
|
42
|
-
d: "M12 10V3.55405e-05L8 0C8 2.4436 6.09369 4.43749 3.79039 4.43749C2.41431 4.43749 1.47239 3.75438 1.02718 3.3367C0.832174 3.15714 0.552541 3.12591 0.324419 3.25863C0.0484661 3.41867 -0.0692741 3.76609 0.0411073 4.07837C0.604052 5.61245 2.60563 9.83215 7.73469 10H12Z",
|
|
43
|
-
fill: color
|
|
44
|
-
})
|
|
49
|
+
children: renderSvgContent()
|
|
45
50
|
});
|
|
46
51
|
};
|
|
47
52
|
exports.ChatBubbleEar = ChatBubbleEar;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_react","_interopRequireDefault","require","_reactNativeSvg","_interopRequireWildcard","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","ChatBubbleEar","type","color","props","
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireDefault","require","_reactNativeSvg","_interopRequireWildcard","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","ChatBubbleEar","type","color","mirrored","props","transform","scaleX","undefined","renderSvgContent","jsxs","Fragment","children","jsx","Path","d","fill","stroke","strokeMiterlimit","width","height","viewBox","style","exports"],"sourceRoot":"../../../../../../src","sources":["components/ChatBubble/components/ChatBubbleEar/index.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GA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AAK,GAAG,SAAS;EACjBC,QAAQ,GAAG,KAAK;EAChB,GAAGC;AACL,CAAC,KAAK;EACJ,MAAMC,SAAS,GAAGF,QAAQ,GAAG,CAAC;IAAEG,MAAM,EAAE,CAAC;EAAE,CAAC,CAAC,GAAGC,SAAS;EAEzD,SAASC,gBAAgBA,CAAA,EAAG;IAC1B,IAAIP,IAAI,KAAK,SAAS,EAAE;MACtB,oBACE,IAAArB,WAAA,CAAA6B,IAAA,EAAA7B,WAAA,CAAA8B,QAAA;QAAAC,QAAA,gBACE,IAAA/B,WAAA,CAAAgC,GAAA,EAAClC,eAAA,CAAAmC,IAAI;UACHC,CAAC,EAAC,gVAAgV;UAClVC,IAAI,EAAEb,KAAM;UACZc,MAAM,EAAC,SAAS;UAChBC,gBAAgB,EAAE;QAAG,CACtB,CAAC,eACF,IAAArC,WAAA,CAAAgC,GAAA,EAAClC,eAAA,CAAAmC,IAAI;UACHC,CAAC,EAAC,sDAAsD;UACxDC,IAAI,EAAEb;QAAM,CACb,CAAC;MAAA,CACF,CAAC;IAEP;IAEA,oBACE,IAAAtB,WAAA,CAAAgC,GAAA,EAAClC,eAAA,CAAAmC,IAAI;MACHC,CAAC,EAAC,0QAA0Q;MAC5QC,IAAI,EAAEb;IAAM,CACb,CAAC;EAEN;EAEA,oBACE,IAAAtB,WAAA,CAAAgC,GAAA,EAAClC,eAAA,CAAAa,OAAG;IACF2B,KAAK,EAAE,EAAG;IACVC,MAAM,EAAE,EAAG;IACXC,OAAO,EAAC,WAAW;IACnBL,IAAI,EAAC,MAAM;IACXM,KAAK,EAAE;MAAEhB;IAAU,CAAE;IAAA,GACjBD,KAAK;IAAAO,QAAA,EAERH,gBAAgB,CAAC;EAAC,CAChB,CAAC;AAEV,CAAC;AAACc,OAAA,CAAAtB,aAAA,GAAAA,aAAA","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sourceRoot":"../../../../../../src","sources":["components/ChatBubble/components/ChatBubbleEar/types.ts"],"mappings":"","ignoreList":[]}
|
|
@@ -4,12 +4,12 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.ChatBubbleText = void 0;
|
|
7
|
-
var _react =
|
|
7
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
8
8
|
var _tailwindPreset = require("@kivid/tailwind-preset");
|
|
9
9
|
var _index = require("../../../Typography/index.js");
|
|
10
10
|
var _index2 = require("../../contexts/index.js");
|
|
11
11
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
12
|
-
function
|
|
12
|
+
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
|
|
13
13
|
/**
|
|
14
14
|
* Typography component for bubble text content
|
|
15
15
|
*/
|
|
@@ -24,7 +24,12 @@ const ChatBubbleText = ({
|
|
|
24
24
|
} = (0, _index2.useChatBubbleContext)();
|
|
25
25
|
|
|
26
26
|
// Text color based on bubble colorState
|
|
27
|
-
const textColorClass =
|
|
27
|
+
const textColorClass = (0, _react.useMemo)(() => {
|
|
28
|
+
if (colorState === "fill") {
|
|
29
|
+
return "text-chia-200";
|
|
30
|
+
}
|
|
31
|
+
return "text-chia-800";
|
|
32
|
+
}, [colorState, variant]);
|
|
28
33
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_index.Typography, {
|
|
29
34
|
variant: "body_large",
|
|
30
35
|
weight: "600",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_react","
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireWildcard","require","_tailwindPreset","_index","_index2","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","ChatBubbleText","className","children","props","colorState","variant","useChatBubbleContext","textColorClass","useMemo","jsx","Typography","weight","merge","exports","displayName"],"sourceRoot":"../../../../../../src","sources":["components/ChatBubble/components/ChatBubbleText/index.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,eAAA,GAAAD,OAAA;AACA,IAAAE,MAAA,GAAAF,OAAA;AAGA,IAAAG,OAAA,GAAAH,OAAA;AAAsD,IAAAI,WAAA,GAAAJ,OAAA;AAAA,SAAAD,wBAAAM,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAR,uBAAA,YAAAA,CAAAM,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAQ,CAAA,MAAAF,CAAA,GAAAL,CAAA,GAAAG,CAAA,GAAAD,CAAA,QAAAG,CAAA,CAAAK,GAAA,CAAAX,CAAA,UAAAM,CAAA,CAAAM,GAAA,CAAAZ,CAAA,GAAAM,CAAA,CAAAO,GAAA,CAAAb,CAAA,EAAAQ,CAAA,gBAAAP,CAAA,IAAAD,CAAA,gBAAAC,CAAA,OAAAa,cAAA,CAAAC,IAAA,CAAAf,CAAA,EAAAC,CAAA,OAAAM,CAAA,IAAAD,CAAA,GAAAU,MAAA,CAAAC,cAAA,KAAAD,MAAA,CAAAE,wBAAA,CAAAlB,CAAA,EAAAC,CAAA,OAAAM,CAAA,CAAAK,GAAA,IAAAL,CAAA,CAAAM,GAAA,IAAAP,CAAA,CAAAE,CAAA,EAAAP,CAAA,EAAAM,CAAA,IAAAC,CAAA,CAAAP,CAAA,IAAAD,CAAA,CAAAC,CAAA,WAAAO,CAAA,KAAAR,CAAA,EAAAC,CAAA;AAEtD;AACA;AACA;AACO,MAAMkB,cAA6C,GAAGA,CAAC;EAC5DC,SAAS;EACTC,QAAQ;EACR,GAAGC;AACL,CAAC,KAAK;EACJ,MAAM;IAAEC,UAAU;IAAEC;EAAQ,CAAC,GAAG,IAAAC,4BAAoB,EAAC,CAAC;;EAEtD;EACA,MAAMC,cAAc,GAAG,IAAAC,cAAO,EAAC,MAAM;IACnC,IAAIJ,UAAU,KAAK,MAAM,EAAE;MACzB,OAAO,eAAe;IACxB;IAEA,OAAO,eAAe;EACxB,CAAC,EAAE,CAACA,UAAU,EAAEC,OAAO,CAAC,CAAC;EAEzB,oBACE,IAAAzB,WAAA,CAAA6B,GAAA,EAAC/B,MAAA,CAAAgC,UAAU;IACTL,OAAO,EAAC,YAAY;IACpBM,MAAM,EAAC,KAAK;IACZV,SAAS,EAAE,IAAAW,qBAAK,EAACL,cAAc,EAAE,aAAa,EAAEN,SAAS,CAAE;IAAA,GACvDE,KAAK;IAAAD,QAAA,EAERA;EAAQ,CACC,CAAC;AAEjB,CAAC;AAACW,OAAA,CAAAb,cAAA,GAAAA,cAAA;AAEFA,cAAc,CAACc,WAAW,GAAG,iBAAiB","ignoreList":[]}
|
|
@@ -9,6 +9,7 @@ var _reactNative = require("react-native");
|
|
|
9
9
|
var _tailwindPreset = require("@kivid/tailwind-preset");
|
|
10
10
|
var _index = require("../../../Typography/index.js");
|
|
11
11
|
var _classVariants = require("../../assets/class-variants.js");
|
|
12
|
+
var _index2 = require("../../contexts/ChatBubbleContext/index.js");
|
|
12
13
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
13
14
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
14
15
|
/**
|
|
@@ -19,8 +20,13 @@ const ChatBubbleTime = ({
|
|
|
19
20
|
children,
|
|
20
21
|
...props
|
|
21
22
|
}) => {
|
|
23
|
+
const {
|
|
24
|
+
origin
|
|
25
|
+
} = (0, _index2.useChatBubbleContext)();
|
|
22
26
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
23
|
-
className: (0, _classVariants.chatBubbleTimeVariants)(
|
|
27
|
+
className: (0, _classVariants.chatBubbleTimeVariants)({
|
|
28
|
+
origin
|
|
29
|
+
}),
|
|
24
30
|
accessibilityLabel: `Message time: ${children}`,
|
|
25
31
|
accessibilityRole: "text",
|
|
26
32
|
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_index.Typography, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_react","_interopRequireDefault","require","_reactNative","_tailwindPreset","_index","_classVariants","_jsxRuntime","e","__esModule","default","ChatBubbleTime","className","children","props","jsx","View","chatBubbleTimeVariants","accessibilityLabel","accessibilityRole","Typography","variant","weight","merge","exports","displayName"],"sourceRoot":"../../../../../../src","sources":["components/ChatBubble/components/ChatBubbleTime/index.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,eAAA,GAAAF,OAAA;AACA,IAAAG,MAAA,GAAAH,OAAA;AACA,IAAAI,cAAA,GAAAJ,OAAA;
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireDefault","require","_reactNative","_tailwindPreset","_index","_classVariants","_index2","_jsxRuntime","e","__esModule","default","ChatBubbleTime","className","children","props","origin","useChatBubbleContext","jsx","View","chatBubbleTimeVariants","accessibilityLabel","accessibilityRole","Typography","variant","weight","merge","exports","displayName"],"sourceRoot":"../../../../../../src","sources":["components/ChatBubble/components/ChatBubbleTime/index.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,eAAA,GAAAF,OAAA;AACA,IAAAG,MAAA,GAAAH,OAAA;AACA,IAAAI,cAAA,GAAAJ,OAAA;AAEA,IAAAK,OAAA,GAAAL,OAAA;AAAwE,IAAAM,WAAA,GAAAN,OAAA;AAAA,SAAAD,uBAAAQ,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAExE;AACA;AACA;AACO,MAAMG,cAA6C,GAAGA,CAAC;EAC5DC,SAAS;EACTC,QAAQ;EACR,GAAGC;AACL,CAAC,KAAK;EACJ,MAAM;IAAEC;EAAO,CAAC,GAAG,IAAAC,4BAAoB,EAAC,CAAC;EAEzC,oBACE,IAAAT,WAAA,CAAAU,GAAA,EAACf,YAAA,CAAAgB,IAAI;IACHN,SAAS,EAAE,IAAAO,qCAAsB,EAAC;MAAEJ;IAAO,CAAC,CAAE;IAC9CK,kBAAkB,EAAE,iBAAiBP,QAAQ,EAAG;IAChDQ,iBAAiB,EAAC,MAAM;IAAAR,QAAA,eAExB,IAAAN,WAAA,CAAAU,GAAA,EAACb,MAAA,CAAAkB,UAAU;MACTC,OAAO,EAAC,aAAa;MACrBC,MAAM,EAAC,KAAK;MACZZ,SAAS,EAAE,IAAAa,qBAAK,EAAC,eAAe,EAAEb,SAAS,CAAE;MAAA,GACzCE,KAAK;MAAAD,QAAA,EAERA;IAAQ,CACC;EAAC,CACT,CAAC;AAEX,CAAC;AAACa,OAAA,CAAAf,cAAA,GAAAA,cAAA;AAEFA,cAAc,CAACgB,WAAW,GAAG,iBAAiB","ignoreList":[]}
|
|
@@ -6,6 +6,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.ChatBubble = ChatBubble;
|
|
7
7
|
var _reactNative = require("react-native");
|
|
8
8
|
var _index = require("./components/index.js");
|
|
9
|
+
var _classVarianceAuthority = require("class-variance-authority");
|
|
9
10
|
var _classVariants = require("./assets/class-variants.js");
|
|
10
11
|
var _index2 = require("../../styles/mixins/shadows/index.js");
|
|
11
12
|
var _tailwindPreset = require("@kivid/tailwind-preset");
|
|
@@ -21,6 +22,7 @@ function ChatBubble(props) {
|
|
|
21
22
|
children,
|
|
22
23
|
time: timeFromProps,
|
|
23
24
|
shouldDisplayTime = true,
|
|
25
|
+
origin = "assistant",
|
|
24
26
|
messageType = "initial",
|
|
25
27
|
chatBubbleBoxClassName,
|
|
26
28
|
fullWidth = false,
|
|
@@ -31,17 +33,23 @@ function ChatBubble(props) {
|
|
|
31
33
|
const [hours, minutes] = new Date().toLocaleTimeString().split(":");
|
|
32
34
|
return `${hours}:${minutes}`;
|
|
33
35
|
}, [timeFromProps]);
|
|
34
|
-
const colorMap = {
|
|
36
|
+
const colorMap = (0, _react.useMemo)(() => ({
|
|
35
37
|
check: "#3DCC78",
|
|
36
38
|
alert: "#FF8B59",
|
|
37
39
|
error: "#E65245",
|
|
38
|
-
custom: "#FAFCFC"
|
|
39
|
-
};
|
|
40
|
-
const tailColor =
|
|
40
|
+
custom: origin === "user" ? "#7A50D9" : "#FAFCFC"
|
|
41
|
+
}), [origin]);
|
|
42
|
+
const tailColor = (0, _react.useMemo)(() => {
|
|
43
|
+
if (colorState === "outline") {
|
|
44
|
+
return "#FAFCFC";
|
|
45
|
+
}
|
|
46
|
+
return colorMap[variant];
|
|
47
|
+
}, [colorMap, colorState, variant]);
|
|
41
48
|
const contextInitialValue = {
|
|
42
49
|
variant,
|
|
43
50
|
colorState,
|
|
44
|
-
messageType
|
|
51
|
+
messageType,
|
|
52
|
+
origin
|
|
45
53
|
};
|
|
46
54
|
const accessibilityLabelMap = {
|
|
47
55
|
check: "Success message",
|
|
@@ -53,19 +61,50 @@ function ChatBubble(props) {
|
|
|
53
61
|
if (hasEar) {
|
|
54
62
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_index.ChatBubbleEar, {
|
|
55
63
|
color: tailColor,
|
|
56
|
-
type: colorState
|
|
64
|
+
type: colorState,
|
|
65
|
+
mirrored: origin === "user"
|
|
57
66
|
});
|
|
58
67
|
}
|
|
59
68
|
return null;
|
|
60
69
|
}
|
|
61
|
-
const bubbleWithEarOffset =
|
|
62
|
-
|
|
70
|
+
const bubbleWithEarOffset = (0, _react.useMemo)(() => {
|
|
71
|
+
if (origin === "user") {
|
|
72
|
+
if (!hasEar) {
|
|
73
|
+
return "mr-[8px]";
|
|
74
|
+
}
|
|
75
|
+
return "";
|
|
76
|
+
}
|
|
77
|
+
if (origin === "assistant") {
|
|
78
|
+
if (!hasEar) {
|
|
79
|
+
return "ml-[8px]";
|
|
80
|
+
}
|
|
81
|
+
return "";
|
|
82
|
+
}
|
|
83
|
+
return "";
|
|
84
|
+
}, [hasEar, origin]);
|
|
85
|
+
const bubbleRowClass = (0, _classVarianceAuthority.cva)("relative flex-row items-end ", {
|
|
86
|
+
variants: {
|
|
87
|
+
origin: {
|
|
88
|
+
user: `flex-row-reverse ${bubbleWithEarOffset}`,
|
|
89
|
+
assistant: bubbleWithEarOffset
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
});
|
|
93
|
+
const bubbleEarContainerClass = (0, _classVarianceAuthority.cva)("w-[12px] h-[10px] pb-[0.2px] z-10 items-center justify-center", {
|
|
94
|
+
variants: {
|
|
95
|
+
origin: {
|
|
96
|
+
user: "ml-[-4px]",
|
|
97
|
+
assistant: "mr-[-4px]"
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
});
|
|
63
101
|
const chatBubbleBoxStyle = (0, _tailwindPreset.merge)((0, _classVariants.chatBubbleBoxVariants)({
|
|
64
102
|
variant,
|
|
65
103
|
colorState,
|
|
66
104
|
hasEar,
|
|
67
105
|
messageType,
|
|
68
|
-
fullWidth
|
|
106
|
+
fullWidth,
|
|
107
|
+
origin
|
|
69
108
|
}), chatBubbleBoxClassName);
|
|
70
109
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_index3.ChatBubbleContext.Provider, {
|
|
71
110
|
value: contextInitialValue,
|
|
@@ -73,12 +112,18 @@ function ChatBubble(props) {
|
|
|
73
112
|
accessibilityRole: "text",
|
|
74
113
|
accessibilityLabel: accessibilityLabelMap[variant],
|
|
75
114
|
accessible: true,
|
|
76
|
-
className: (0, _tailwindPreset.merge)(
|
|
115
|
+
className: (0, _tailwindPreset.merge)((0, _classVariants.chatBubbleContainerVariants)({
|
|
116
|
+
origin
|
|
117
|
+
}), className),
|
|
77
118
|
...restOfProps,
|
|
78
119
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
|
|
79
|
-
className: bubbleRowClass
|
|
80
|
-
|
|
81
|
-
|
|
120
|
+
className: bubbleRowClass({
|
|
121
|
+
origin
|
|
122
|
+
}),
|
|
123
|
+
children: [hasEar && /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
124
|
+
className: bubbleEarContainerClass({
|
|
125
|
+
origin
|
|
126
|
+
}),
|
|
82
127
|
accessibilityElementsHidden: true,
|
|
83
128
|
importantForAccessibility: "no-hide-descendants",
|
|
84
129
|
children: renderChatBubbleEar()
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_reactNative","require","_index","_classVariants","_index2","_tailwindPreset","_index3","_react","_jsxRuntime","ChatBubble","props","variant","colorState","hasEar","className","children","time","timeFromProps","shouldDisplayTime","messageType","chatBubbleBoxClassName","fullWidth","restOfProps","useMemo","hours","minutes","Date","toLocaleTimeString","split","colorMap","check","alert","error","custom","tailColor","contextInitialValue","accessibilityLabelMap","renderChatBubbleEar","jsx","ChatBubbleEar","color","type","bubbleWithEarOffset","bubbleRowClass","chatBubbleBoxStyle","merge","chatBubbleBoxVariants","ChatBubbleContext","Provider","value","jsxs","View","accessibilityRole","accessibilityLabel","accessible","accessibilityElementsHidden","importantForAccessibility","style","boxShadow","elevationDown100","ChatBubbleTime","Content","ChatBubbleContent","Seal","ChatBubbleSeal","Text","ChatBubbleText","Loading","ChatBubbleLoading","displayName"],"sourceRoot":"../../../../src","sources":["components/ChatBubble/index.tsx"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AACA,IAAAC,MAAA,GAAAD,OAAA;
|
|
1
|
+
{"version":3,"names":["_reactNative","require","_index","_classVarianceAuthority","_classVariants","_index2","_tailwindPreset","_index3","_react","_jsxRuntime","ChatBubble","props","variant","colorState","hasEar","className","children","time","timeFromProps","shouldDisplayTime","origin","messageType","chatBubbleBoxClassName","fullWidth","restOfProps","useMemo","hours","minutes","Date","toLocaleTimeString","split","colorMap","check","alert","error","custom","tailColor","contextInitialValue","accessibilityLabelMap","renderChatBubbleEar","jsx","ChatBubbleEar","color","type","mirrored","bubbleWithEarOffset","bubbleRowClass","cva","variants","user","assistant","bubbleEarContainerClass","chatBubbleBoxStyle","merge","chatBubbleBoxVariants","ChatBubbleContext","Provider","value","jsxs","View","accessibilityRole","accessibilityLabel","accessible","chatBubbleContainerVariants","accessibilityElementsHidden","importantForAccessibility","style","boxShadow","elevationDown100","ChatBubbleTime","Content","ChatBubbleContent","Seal","ChatBubbleSeal","Text","ChatBubbleText","Loading","ChatBubbleLoading","displayName"],"sourceRoot":"../../../../src","sources":["components/ChatBubble/index.tsx"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AACA,IAAAC,MAAA,GAAAD,OAAA;AAQA,IAAAE,uBAAA,GAAAF,OAAA;AAEA,IAAAG,cAAA,GAAAH,OAAA;AAKA,IAAAI,OAAA,GAAAJ,OAAA;AACA,IAAAK,eAAA,GAAAL,OAAA;AACA,IAAAM,OAAA,GAAAN,OAAA;AAEA,IAAAO,MAAA,GAAAP,OAAA;AAAgC,IAAAQ,WAAA,GAAAR,OAAA;AAEzB,SAASS,UAAUA,CAACC,KAAsB,EAAE;EACjD,MAAM;IACJC,OAAO,GAAG,QAAQ;IAClBC,UAAU,GAAG,SAAS;IACtBC,MAAM,GAAG,IAAI;IACbC,SAAS;IACTC,QAA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AO,GAAGC,wBAAiB;AAEtCnE,UAAU,CAACoE,WAAW,GAAG,YAAY","ignoreList":[]}
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.defaultTheme = void 0;
|
|
7
|
+
const defaultTheme = exports.defaultTheme = {
|
|
8
|
+
backgroundColor: "#FAFCFC",
|
|
9
|
+
calendarBackground: "#FAFCFC",
|
|
10
|
+
textSectionTitleColor: "#6B7280",
|
|
11
|
+
textSectionTitleDisabledColor: "#D1D5DB",
|
|
12
|
+
selectedDayBackgroundColor: "#EAE0FF",
|
|
13
|
+
selectedDayTextColor: "#1F2937",
|
|
14
|
+
todayTextColor: "#1F2937",
|
|
15
|
+
dayTextColor: "#1F2937",
|
|
16
|
+
textDisabledColor: "#D1D5DB",
|
|
17
|
+
dotColor: "#1F2937",
|
|
18
|
+
selectedDotColor: "#1F2937",
|
|
19
|
+
arrowColor: "#1F2937",
|
|
20
|
+
disabledArrowColor: "#D1D5DB",
|
|
21
|
+
monthTextColor: "#1F2937",
|
|
22
|
+
indicatorColor: "#1F2937",
|
|
23
|
+
textDayFontFamily: "System",
|
|
24
|
+
textMonthFontFamily: "System",
|
|
25
|
+
textDayHeaderFontFamily: "System",
|
|
26
|
+
textDayFontWeight: "500",
|
|
27
|
+
textMonthFontWeight: "600",
|
|
28
|
+
textDayHeaderFontWeight: "700",
|
|
29
|
+
textDayFontSize: 16,
|
|
30
|
+
textMonthFontSize: 18,
|
|
31
|
+
textDayHeaderFontSize: 13.5,
|
|
32
|
+
"stylesheet.calendar.header": {
|
|
33
|
+
header: {
|
|
34
|
+
flexDirection: "row",
|
|
35
|
+
justifyContent: "space-between",
|
|
36
|
+
alignItems: "center",
|
|
37
|
+
backgroundColor: "#FAFCFC",
|
|
38
|
+
borderBottomWidth: 1,
|
|
39
|
+
borderBottomColor: "#DEE7E7"
|
|
40
|
+
},
|
|
41
|
+
monthText: {
|
|
42
|
+
fontSize: 18,
|
|
43
|
+
fontWeight: "600",
|
|
44
|
+
color: "#1F2937"
|
|
45
|
+
},
|
|
46
|
+
arrow: {
|
|
47
|
+
padding: 0
|
|
48
|
+
},
|
|
49
|
+
arrowImage: {
|
|
50
|
+
tintColor: "#1F2937"
|
|
51
|
+
},
|
|
52
|
+
week: {
|
|
53
|
+
marginTop: 16,
|
|
54
|
+
marginBottom: 8,
|
|
55
|
+
flexDirection: "row",
|
|
56
|
+
justifyContent: "space-around"
|
|
57
|
+
}
|
|
58
|
+
},
|
|
59
|
+
"stylesheet.day.basic": {
|
|
60
|
+
base: {
|
|
61
|
+
width: 40,
|
|
62
|
+
height: 35,
|
|
63
|
+
alignItems: "center",
|
|
64
|
+
justifyContent: "center",
|
|
65
|
+
borderWidth: 1,
|
|
66
|
+
borderColor: "#DEE7E7",
|
|
67
|
+
borderRadius: 8,
|
|
68
|
+
paddingTop: 6,
|
|
69
|
+
paddingBottom: 4
|
|
70
|
+
},
|
|
71
|
+
text: {
|
|
72
|
+
fontSize: 16,
|
|
73
|
+
fontWeight: "500",
|
|
74
|
+
color: "#1F2937"
|
|
75
|
+
},
|
|
76
|
+
selected: {
|
|
77
|
+
backgroundColor: "#EAE0FF",
|
|
78
|
+
borderWidth: 1,
|
|
79
|
+
borderColor: "#B9A0F2"
|
|
80
|
+
},
|
|
81
|
+
today: {
|
|
82
|
+
backgroundColor: "transparent",
|
|
83
|
+
borderWidth: 1,
|
|
84
|
+
borderColor: "#DEE7E7"
|
|
85
|
+
},
|
|
86
|
+
todayText: {
|
|
87
|
+
color: "#1F2937",
|
|
88
|
+
fontWeight: "600"
|
|
89
|
+
},
|
|
90
|
+
disabled: {
|
|
91
|
+
opacity: 0.3,
|
|
92
|
+
borderWidth: 0
|
|
93
|
+
},
|
|
94
|
+
disabledText: {
|
|
95
|
+
color: "#D1D5DB"
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
};
|
|
99
|
+
//# sourceMappingURL=theme.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["defaultTheme","exports","backgroundColor","calendarBackground","textSectionTitleColor","textSectionTitleDisabledColor","selectedDayBackgroundColor","selectedDayTextColor","todayTextColor","dayTextColor","textDisabledColor","dotColor","selectedDotColor","arrowColor","disabledArrowColor","monthTextColor","indicatorColor","textDayFontFamily","textMonthFontFamily","textDayHeaderFontFamily","textDayFontWeight","textMonthFontWeight","textDayHeaderFontWeight","textDayFontSize","textMonthFontSize","textDayHeaderFontSize","header","flexDirection","justifyContent","alignItems","borderBottomWidth","borderBottomColor","monthText","fontSize","fontWeight","color","arrow","padding","arrowImage","tintColor","week","marginTop","marginBottom","base","width","height","borderWidth","borderColor","borderRadius","paddingTop","paddingBottom","text","selected","today","todayText","disabled","opacity","disabledText"],"sourceRoot":"../../../../../src","sources":["components/DatePicker/assets/theme.ts"],"mappings":";;;;;;AAAO,MAAMA,YAAY,GAAAC,OAAA,CAAAD,YAAA,GAAG;EAC1BE,eAAe,EAAE,SAAS;EAC1BC,kBAAkB,EAAE,SAAS;EAC7BC,qBAAqB,EAAE,SAAS;EAChCC,6BAA6B,EAAE,SAAS;EACxCC,0BAA0B,EAAE,SAAS;EACrCC,oBAAoB,EAAE,SAAS;EAC/BC,cAAc,EAAE,SAAS;EACzBC,YAAY,EAAE,SAAS;EACvBC,iBAAiB,EAAE,SAAS;EAC5BC,QAAQ,EAAE,SAAS;EACnBC,gBAAgB,EAAE,SAAS;EAC3BC,UAAU,EAAE,SAAS;EACrBC,kBAAkB,EAAE,SAAS;EAC7BC,cAAc,EAAE,SAAS;EACzBC,cAAc,EAAE,SAAS;EACzBC,iBAAiB,EAAE,QAAQ;EAC3BC,mBAAmB,EAAE,QAAQ;EAC7BC,uBAAuB,EAAE,QAAQ;EACjCC,iBAAiB,EAAE,KAAc;EACjCC,mBAAmB,EAAE,KAAc;EACnCC,uBAAuB,EAAE,KAAc;EACv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