@mekari/pixel3-upload 0.0.15 → 0.0.16-dev.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.
@@ -92,17 +92,21 @@ function useUploadList(props, emit) {
92
92
  isShowDownloadButton,
93
93
  isShowRemoveButton
94
94
  } = (0, import_vue.toRefs)(props);
95
+ const {
96
+ isNextTheme
97
+ } = (0, import_pixel3_utils.usePixelTheme)();
95
98
  const getId = id.value || (0, import_pixel3_utils.getUniqueId)("", "upload-list").value;
96
99
  const color = (0, import_vue.computed)(() => {
97
- let title = "dark";
98
- let subtitle = "gray.600";
100
+ let title = isNextTheme.value ? "text.default" : "dark";
101
+ let subtitle = isNextTheme.value ? "text.secondary" : "gray.600";
99
102
  if (status.value === "success") {
100
- title = "blue.700";
103
+ title = isNextTheme.value ? "text.success" : "blue.700";
101
104
  }
102
105
  if (status.value === "error") {
103
- title = "red.400";
104
- subtitle = "red.400";
106
+ title = isNextTheme.value ? "text.danger" : "red.400";
107
+ subtitle = isNextTheme.value ? "text.danger" : "red.400";
105
108
  }
109
+ console.log("ada", title, subtitle);
106
110
  return {
107
111
  title,
108
112
  subtitle
@@ -129,8 +133,8 @@ function useUploadList(props, emit) {
129
133
  return {
130
134
  size: "md",
131
135
  name: status.value === "error" ? "error" : iconName.value,
132
- color: status.value === "error" ? "red.700" : iconColor.value,
133
- variant: status.value === "error" ? "duotone" : iconVariant.value
136
+ color: status.value === "error" ? isNextTheme.value ? "icon.danger" : "red.700" : iconColor.value,
137
+ variant: status.value === "error" ? isNextTheme.value ? "outline" : "duotone" : iconVariant.value
134
138
  };
135
139
  });
136
140
  const titleWrapperAttrs = (0, import_vue.computed)(() => {
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  MpUploadList
3
- } from "./chunk-W6VPDWGC.mjs";
4
- import "./chunk-IEVDIM2Y.mjs";
3
+ } from "./chunk-DUIAKRG4.mjs";
4
+ import "./chunk-Z5XNNZQB.mjs";
5
5
  import "./chunk-VRL243IV.mjs";
6
6
  import "./chunk-QZ7VFGWC.mjs";
7
7
  export {
package/dist/upload.d.mts CHANGED
@@ -112,9 +112,9 @@ declare const MpUpload: vue.DefineComponent<{
112
112
  }>> & {
113
113
  [x: `on${Capitalize<string>}`]: ((...args: any[]) => any) | undefined;
114
114
  }, {
115
+ id: string;
115
116
  isDisabled: boolean;
116
117
  isLoading: boolean;
117
- id: string;
118
118
  placeholder: string;
119
119
  loadingText: string;
120
120
  buttonText: string;
package/dist/upload.d.ts CHANGED
@@ -112,9 +112,9 @@ declare const MpUpload: vue.DefineComponent<{
112
112
  }>> & {
113
113
  [x: `on${Capitalize<string>}`]: ((...args: any[]) => any) | undefined;
114
114
  }, {
115
+ id: string;
115
116
  isDisabled: boolean;
116
117
  isLoading: boolean;
117
- id: string;
118
118
  placeholder: string;
119
119
  loadingText: string;
120
120
  buttonText: string;
package/dist/upload.js CHANGED
@@ -110,6 +110,9 @@ function useUpload(props, emit) {
110
110
  } = (0, import_vue.toRefs)(props);
111
111
  const files = (0, import_vue.ref)(fileList == null ? void 0 : fileList.value);
112
112
  const fileInput = (0, import_vue.ref)();
113
+ const {
114
+ isNextTheme
115
+ } = (0, import_pixel3_utils.usePixelTheme)();
113
116
  const getId = id.value || (0, import_pixel3_utils.getUniqueId)("", "upload").value;
114
117
  const fileName = (0, import_vue.computed)(() => {
115
118
  if (isLoading.value) {
@@ -153,12 +156,10 @@ function useUpload(props, emit) {
153
156
  isDisabled: isDisabled.value
154
157
  };
155
158
  });
156
- const textAttrs = (0, import_vue.computed)(() => {
157
- return {
158
- color: !isLoading.value && totalFiles.value >= 1 ? "dark" : "gray.400",
159
- isTruncated: true
160
- };
161
- });
159
+ const textAttrs = (0, import_vue.computed)(() => ({
160
+ color: !isLoading.value && totalFiles.value >= 1 ? isNextTheme ? "text.default" : "dark" : isNextTheme ? "text.secondary" : "gray.400",
161
+ isTruncated: true
162
+ }));
162
163
  const resetButtonAttrs = (0, import_vue.computed)(() => {
163
164
  return {
164
165
  class: (0, import_recipes.uploadSlotRecipe)().resetButton,
package/dist/upload.mjs CHANGED
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  MpUpload
3
- } from "./chunk-O5TCYA7V.mjs";
4
- import "./chunk-IEVDIM2Y.mjs";
3
+ } from "./chunk-ADYWIIBK.mjs";
4
+ import "./chunk-Z5XNNZQB.mjs";
5
5
  import "./chunk-VRL243IV.mjs";
6
6
  import "./chunk-QZ7VFGWC.mjs";
7
7
  export {
package/package.json CHANGED
@@ -1,19 +1,19 @@
1
1
  {
2
2
  "name": "@mekari/pixel3-upload",
3
3
  "description": "Upload component for mekari pixel 3",
4
- "version": "0.0.15",
4
+ "version": "0.0.16-dev.0",
5
5
  "main": "dist/index.js",
6
6
  "license": "MIT",
7
7
  "files": [
8
8
  "dist"
9
9
  ],
10
10
  "dependencies": {
11
- "@mekari/pixel3-button": "0.0.16",
12
- "@mekari/pixel3-icon": "0.0.16",
13
- "@mekari/pixel3-styled-system": "0.1.1",
14
- "@mekari/pixel3-spinner": "0.0.16",
15
- "@mekari/pixel3-text": "0.0.15",
16
- "@mekari/pixel3-utils": "0.0.6"
11
+ "@mekari/pixel3-button": "0.0.17-dev.0",
12
+ "@mekari/pixel3-spinner": "0.0.17-dev.0",
13
+ "@mekari/pixel3-icon": "0.0.17-dev.0",
14
+ "@mekari/pixel3-text": "0.0.16-dev.0",
15
+ "@mekari/pixel3-styled-system": "0.1.2-dev.0",
16
+ "@mekari/pixel3-utils": "0.0.7-dev.0"
17
17
  },
18
18
  "peerDependencies": {
19
19
  "vue": "^3.4.9"