@qikdev/vue-ui 0.1.53 → 0.1.55

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/lib.es.js CHANGED
@@ -32,7 +32,7 @@ var __objRest = (source, exclude) => {
32
32
  };
33
33
  import { openBlock, createElementBlock, renderSlot, resolveComponent, createBlock, withCtx, createVNode, Fragment, renderList, normalizeClass, toDisplayString, withDirectives, resolveDynamicComponent, vShow, withModifiers, createTextVNode, createCommentVNode, createElementVNode, mergeProps, toHandlers, pushScopeId, popScopeId, normalizeStyle, Teleport, vModelSelect, withKeys, vModelText, TransitionGroup, defineComponent, h, nextTick, vModelDynamic, vModelCheckbox, reactive, watch } from "vue";
34
34
  import { EventDispatcher } from "@qikdev/sdk";
35
- const version$1 = "0.1.53";
35
+ const version$1 = "0.1.55";
36
36
  var flexColumn_vue_vue_type_style_index_0_scoped_true_lang = "";
37
37
  var _export_sfc = (sfc, props2) => {
38
38
  const target = sfc.__vccOpts || sfc;
@@ -5921,6 +5921,9 @@ const _sfc_main$J = {
5921
5921
  type: {
5922
5922
  type: String,
5923
5923
  default: "image"
5924
+ },
5925
+ svg: {
5926
+ type: Boolean
5924
5927
  }
5925
5928
  },
5926
5929
  data() {
@@ -5929,6 +5932,17 @@ const _sfc_main$J = {
5929
5932
  };
5930
5933
  },
5931
5934
  computed: {
5935
+ isSvg() {
5936
+ var _a;
5937
+ if (this.svg) {
5938
+ return true;
5939
+ }
5940
+ switch ((_a = this.item) == null ? void 0 : _a.fileMime) {
5941
+ case "image/svg+xml":
5942
+ case "image/svg":
5943
+ return true;
5944
+ }
5945
+ },
5932
5946
  defaultWidth() {
5933
5947
  return;
5934
5948
  },
@@ -5995,7 +6009,11 @@ const _sfc_main$J = {
5995
6009
  style.height = 0;
5996
6010
  style.paddingBottom = `${dimensionHeight / dimensionWidth * 100}%`;
5997
6011
  }
5998
- style.backgroundImage = `url(${this.previewSrc})`;
6012
+ if (this.isSvg)
6013
+ ;
6014
+ else {
6015
+ style.backgroundImage = `url(${this.previewSrc})`;
6016
+ }
5999
6017
  return style;
6000
6018
  }
6001
6019
  }
@@ -6009,7 +6027,7 @@ function _sfc_render$J(_ctx, _cache, $props, $setup, $data, $options) {
6009
6027
  createElementVNode("img", { src: $options.src }, null, 8, _hoisted_1$D)
6010
6028
  ], 4);
6011
6029
  }
6012
- var UXImage = /* @__PURE__ */ _export_sfc(_sfc_main$J, [["render", _sfc_render$J], ["__scopeId", "data-v-3d48a5ec"]]);
6030
+ var UXImage = /* @__PURE__ */ _export_sfc(_sfc_main$J, [["render", _sfc_render$J], ["__scopeId", "data-v-dee7ea18"]]);
6013
6031
  var progressbar_vue_vue_type_style_index_0_scoped_true_lang = "";
6014
6032
  const _sfc_main$I = {
6015
6033
  props: {
@@ -12626,6 +12644,9 @@ const _sfc_main$o = {
12626
12644
  props: {
12627
12645
  multiple: {
12628
12646
  type: Boolean
12647
+ },
12648
+ accept: {
12649
+ type: String
12629
12650
  }
12630
12651
  },
12631
12652
  methods: {
@@ -12656,7 +12677,7 @@ const _sfc_main$o = {
12656
12677
  }
12657
12678
  }
12658
12679
  };
12659
- const _hoisted_1$j = ["multiple"];
12680
+ const _hoisted_1$j = ["accept", "multiple"];
12660
12681
  const _hoisted_2$f = /* @__PURE__ */ createTextVNode("Select Files");
12661
12682
  function _sfc_render$o(_ctx, _cache, $props, $setup, $data, $options) {
12662
12683
  const _component_ux_button = resolveComponent("ux-button");
@@ -12667,6 +12688,7 @@ function _sfc_render$o(_ctx, _cache, $props, $setup, $data, $options) {
12667
12688
  }, [
12668
12689
  createElementVNode("input", {
12669
12690
  ref: "file",
12691
+ accept: $props.accept,
12670
12692
  type: "file",
12671
12693
  multiple: $props.multiple,
12672
12694
  onChange: _cache[0] || (_cache[0] = ($event) => $options.filesSelected($event.target.files))
@@ -12686,7 +12708,7 @@ function _sfc_render$o(_ctx, _cache, $props, $setup, $data, $options) {
12686
12708
  ])
12687
12709
  ], 32);
12688
12710
  }
12689
- var FileDrop = /* @__PURE__ */ _export_sfc(_sfc_main$o, [["render", _sfc_render$o], ["__scopeId", "data-v-67879182"]]);
12711
+ var FileDrop = /* @__PURE__ */ _export_sfc(_sfc_main$o, [["render", _sfc_render$o], ["__scopeId", "data-v-65e7e548"]]);
12690
12712
  var upload_vue_vue_type_style_index_0_scoped_true_lang = "";
12691
12713
  const _sfc_main$n = {
12692
12714
  mixins: [InputMixin],
@@ -18860,5 +18882,5 @@ const QikUI = {
18860
18882
  }
18861
18883
  }
18862
18884
  };
18863
- export { CodeEditor, ContentBrowser, device as Device, FlexBody, FlexCell, FlexColumn, FlexFooter, FlexHeader, FlexRow, FlexSpacer, ModalMixin, NativeSelect, Panel, PanelBody, PanelFooter, PanelHeader, ProgressBar, QikUI, RememberScrollMixin, Search, Selection, Spinner, UXButton, UXCheckbox, UXForm, UXFormField, UXIcon, UXImage, UXLink, UXList, UXListItem, UXMenu, UXMenuList, UXRender, UXRenderField, UXSubmissionForm, UXSwitch, UXTab, NativeTable as UXTable, UXTabset, UxConfirmModal, UxContentModal, UxModal, UxOptionsModal, UxPromptModal };
18885
+ export { CodeEditor, ContentBrowser, device as Device, FileDrop, FlexBody, FlexCell, FlexColumn, FlexFooter, FlexHeader, FlexRow, FlexSpacer, ModalMixin, NativeSelect, Panel, PanelBody, PanelFooter, PanelHeader, ProgressBar, QikUI, RememberScrollMixin, Search, Selection, Spinner, UXButton, UXCheckbox, UXForm, UXFormField, UXIcon, UXImage, UXLink, UXList, UXListItem, UXMenu, UXMenuList, UXRender, UXRenderField, UXSubmissionForm, UXSwitch, UXTab, NativeTable as UXTable, UXTabset, UxConfirmModal, UxContentModal, UxModal, UxOptionsModal, UxPromptModal };
18864
18886
  //# sourceMappingURL=lib.es.js.map