@opentiny/vue-dropdown-item 2.11.0-alpha.2 → 2.11.1

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/lib/index.js CHANGED
@@ -82,6 +82,7 @@ var dropdownItemProps = _extends({}, $props, {
82
82
  return -1;
83
83
  }
84
84
  },
85
+ // tiny新增
85
86
  appendToBody: {
86
87
  type: Boolean,
87
88
  default: true
@@ -111,7 +112,7 @@ var DropdownItem = defineComponent({
111
112
  });
112
113
  }
113
114
  });
114
- var version = "2.11.0-alpha.2";
115
+ var version = "2.11.1";
115
116
  DropdownItem.model = {
116
117
  prop: "modelValue",
117
118
  event: "update:modelValue"
@@ -55,6 +55,7 @@ function normalizeComponent(scriptExports, render, staticRenderFns, functionalTe
55
55
  }
56
56
 
57
57
  var __vue2_script = defineComponent({
58
+ emits: ["update:modelValue", "change", "closed", "open", "opened", "close", "confirm", "reset"],
58
59
  props: [].concat(props, ["disabled", "icon", "itemData", "selected", "label", "level", "currentIndex"]),
59
60
  setup: function setup(props2, context) {
60
61
  return _setup({
@@ -70,12 +71,11 @@ var render = function render2() {
70
71
  var _h = _vm.$createElement;
71
72
  var _c = _vm._self._c || _h;
72
73
  return _c("li", {
73
- class: _vm.m("list-none leading-10 sm:leading-8 m-0 outline-0 min-w-[theme(spacing.18)] max-w-[theme(spacing.52)] w-full [&_svg]:sm:w-3.5 [&_svg]:sm:h-3.5 [&_svg]:sm:mr-1.5 [&_svg]:mr-2 [&_svg]:align-text-bottom", _vm.disabled ? "cursor-not-allowed text-color-text-disabled [&_svg]:fill-color-text-disabled" : "text-color-text-primary active:bg-color-bg-4 visited:text-color-brand hover:bg-color-bg-4 focus:bg-color-bg-4 cursor-pointer", {
74
- "text-color-brand-focus": _vm.dataStore.checkedStatus && _vm.selected
75
- }, {
76
- "!px-0": _vm.dataStore.multiStage
77
- }),
74
+ class: _vm.m("rounded-sm list-none leading-10 sm:leading-8 outline-0 min-w-[theme(spacing.18)] max-w-[theme(spacing.52)] w-full [&_svg]:sm:w-3.5 [&_svg]:sm:h-3.5 [&_svg]:sm:mr-1.5 [&_svg]:mr-2 [&_svg]:align-text-bottom", _vm.disabled ? "cursor-not-allowed text-color-text-disabled [&_svg]:fill-color-text-disabled" : "text-color-text-primary active:bg-color-bg-4 visited:text-color-brand hover:bg-color-bg-2 focus:bg-color-bg-4 cursor-pointer", {
75
+ "text-color-brand-focus bg-color-fill-6": _vm.dataStore.checkedStatus && _vm.selected
76
+ }, _vm.dataStore.multiStage ? "!px-0 mb-1" : "[&:not(:last-of-type)]:mb-1"),
78
77
  attrs: {
78
+ "data-tag": "tiny-dropdown-item",
79
79
  "aria-disabled": _vm.disabled,
80
80
  "tabindex": _vm.disabled ? null : -1
81
81
  },
@@ -89,7 +89,10 @@ var render = function render2() {
89
89
  }
90
90
  }, [_c("div", {
91
91
  ref: "level",
92
- class: ["sm:text-xs text-sm", _vm.level === "2" ? "mx-6 overflow-hidden text-ellipsis whitespace-nowrap" : "mx-4 sm:mx-3 overflow-hidden text-ellipsis whitespace-nowrap"]
92
+ class: ["sm:text-xs text-sm", _vm.level === "2" ? "mx-6 overflow-hidden text-ellipsis whitespace-nowrap" : "mx-4 sm:mx-3 overflow-hidden text-ellipsis whitespace-nowrap"],
93
+ attrs: {
94
+ "data-tag": "tiny-dropdown-level"
95
+ }
93
96
  }, [_vm.icon ? _c(_vm.icon, {
94
97
  tag: "component",
95
98
  staticClass: "sm:w-3.5 sm:h-3.5 sm:mr-1.5 mr-2 align-text-bottom"
package/lib/pc.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { defineComponent, $prefix, props, setup as _setup } from "@opentiny/vue-common";
2
2
  import { renderless, api } from "@opentiny/vue-renderless/dropdown-item/vue";
3
3
  import { iconDeltaLeft } from "@opentiny/vue-icon";
4
- import Tooltip from "@opentiny/vue-tooltip";
4
+ import TinyTooltip from "@opentiny/vue-tooltip";
5
5
  import "@opentiny/vue-theme/dropdown-item/index.css";
6
6
  function normalizeComponent(scriptExports, render, staticRenderFns, functionalTemplate, injectStyles, scopeId, moduleIdentifier, shadowMode) {
7
7
  var options = typeof scriptExports === "function" ? scriptExports.options : scriptExports;
@@ -64,7 +64,7 @@ var __vue2_script = defineComponent({
64
64
  props: [].concat(props, ["disabled", "divided", "icon", "itemData", "title", "titleClass", "options", "type", "label", "appendToBody", "textField", "selected", "selectedField", "multiStage", "currentIndex", "tip", "tipPosition"]),
65
65
  components: {
66
66
  IconDeltaLeft: iconDeltaLeft(),
67
- TinyTooltip: Tooltip
67
+ TinyTooltip
68
68
  },
69
69
  setup: function setup(props2, context) {
70
70
  return _setup({
@@ -116,11 +116,13 @@ var render = function render2() {
116
116
  }, [_vm.icon ? _c(_vm.icon, {
117
117
  tag: "component",
118
118
  staticClass: "tiny-svg-size"
119
- }) : _vm._e(), _vm._t("default", function() {
119
+ }) : _vm._e(), _c("span", {
120
+ staticClass: "tiny-dropdown-item__label"
121
+ }, [_vm._t("default", function() {
120
122
  return [_c("span", [_vm._v(_vm._s(_vm.label))])];
121
123
  }, {
122
124
  "itemData": _vm.itemData
123
- })], 2), _vm.itemData.children && _vm.itemData.children.length ? _c("ul", {
125
+ })], 2)], 1), _vm.itemData.children && _vm.itemData.children.length ? _c("ul", {
124
126
  class: ["tiny-dropdown-menu", "tiny-dropdown-item--child tiny-dropdown-menu__item--child", _vm.state.popperClass]
125
127
  }, _vm._l(_vm.itemData.children, function(item, index) {
126
128
  return _c("tiny-dropdown-item", {
package/package.json CHANGED
@@ -1,18 +1,18 @@
1
1
  {
2
2
  "name": "@opentiny/vue-dropdown-item",
3
- "version": "2.11.0-alpha.2",
3
+ "version": "2.11.1",
4
4
  "description": "",
5
5
  "main": "./lib/index.js",
6
6
  "module": "./lib/index.js",
7
7
  "sideEffects": false,
8
8
  "type": "module",
9
9
  "dependencies": {
10
- "@opentiny/vue-common": "~2.11.0-alpha.0",
11
- "@opentiny/vue-icon": "~2.11.0-alpha.0",
12
- "@opentiny/vue-renderless": "~3.11.0-alpha.0",
13
- "@opentiny/vue-popup": "~2.11.0-alpha.0",
14
- "@opentiny/vue-button": "~2.11.0-alpha.0",
15
- "@opentiny/vue-tooltip": "~2.11.0-alpha.0"
10
+ "@opentiny/vue-common": "~2.11.0",
11
+ "@opentiny/vue-icon": "~2.11.0",
12
+ "@opentiny/vue-renderless": "~3.11.0",
13
+ "@opentiny/vue-popup": "~2.11.0",
14
+ "@opentiny/vue-button": "~2.11.0",
15
+ "@opentiny/vue-tooltip": "~2.11.0"
16
16
  },
17
17
  "license": "MIT",
18
18
  "types": "index.d.ts",