@finema/core 1.4.135 → 1.4.137

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/module.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@finema/core",
3
- "version": "1.4.135",
3
+ "version": "1.4.137",
4
4
  "configKey": "core",
5
5
  "compatibility": {
6
6
  "nuxt": "^3.7.4"
package/dist/module.mjs CHANGED
@@ -1,7 +1,7 @@
1
1
  import { defineNuxtModule, createResolver, installModule, addPlugin, addComponentsDir, addImportsDir } from '@nuxt/kit';
2
2
 
3
3
  const name = "@finema/core";
4
- const version = "1.4.135";
4
+ const version = "1.4.137";
5
5
 
6
6
  const colors = {
7
7
  black: "#20243E",
@@ -7,7 +7,7 @@
7
7
  {
8
8
  [ui.disabled]: isDisabled,
9
9
  [ui.background.default]: !isOverDropZone && !isDisabled,
10
- [ui.background.dragover]: isOverDropZone && !isDisabled,
10
+ [ui.background.dragover]: isOverDropZone && (!isDisabled || !isReadonly),
11
11
  [ui.failed]: upload.status.value.isError,
12
12
  },
13
13
  ]"
@@ -18,7 +18,7 @@
18
18
  class="hidden"
19
19
  :name="name"
20
20
  :accept="fileAllocate.acceptFile.value"
21
- :disabled="isDisabled"
21
+ :disabled="isDisabled || isReadonly"
22
22
  @change="handleChange"
23
23
  />
24
24
  <div :class="[ui.wrapper]">
@@ -105,6 +105,7 @@
105
105
  @click="handleDownloadFile"
106
106
  />
107
107
  <Icon
108
+ v-if="!(isDisabled || isReadonly)"
108
109
  :name="ui.action.deleteIcon"
109
110
  :class="[ui.action.iconClass]"
110
111
  title="ลบไฟล์"
@@ -246,7 +247,7 @@ const { isOverDropZone } = useDropZone(dropzoneRef as unknown as HTMLElement, {
246
247
  })
247
248
 
248
249
  const handleChange = (e: Event) => {
249
- if (props.isDisabled) return
250
+ if (props.isDisabled || props.isReadonly) return
250
251
 
251
252
  const file = (e.target as HTMLInputElement).files?.[0]
252
253
  const result = handleCheckFileCondition(file)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@finema/core",
3
- "version": "1.4.135",
3
+ "version": "1.4.137",
4
4
  "repository": "https://gitlab.finema.co/finema/ui-kit",
5
5
  "license": "MIT",
6
6
  "author": "Finema Dev Core Team",