yahee-components 0.0.64 → 0.0.65

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.
@@ -1,13 +1,13 @@
1
- import { defineComponent as l, createElementBlock as a, openBlock as m, createVNode as e, unref as o, withCtx as t, createElementVNode as i, renderSlot as f } from "vue";
2
- import { ElTooltip as u, ElIcon as d, ElMessage as _ } from "element-plus";
1
+ import { defineComponent as a, createElementBlock as l, openBlock as m, createVNode as e, unref as o, withCtx as t, createElementVNode as i, renderSlot as f } from "vue";
2
+ import { ElTooltip as u, ElIcon as d, ElMessage as y } from "element-plus";
3
3
  import "element-plus/theme-chalk/src/base.scss";
4
4
  import "element-plus/theme-chalk/src/tooltip.scss";
5
5
  import "element-plus/theme-chalk/src/popper.scss";
6
6
  import "element-plus/theme-chalk/src/badge.scss";
7
7
  import "element-plus/theme-chalk/src/message.scss";
8
8
  import { DocumentCopy as h } from "@element-plus/icons-vue";
9
- import { useClipboard as y } from "../packages/components/hooks/useClipboard.js";
10
- const C = { class: "yahee-copy" }, z = /* @__PURE__ */ l({
9
+ import { useClipboard as _ } from "../packages/components/hooks/useClipboard.js";
10
+ const C = { class: "yahee-copy" }, z = /* @__PURE__ */ a({
11
11
  name: "YaheeCopy",
12
12
  __name: "copy",
13
13
  props: {
@@ -15,26 +15,26 @@ const C = { class: "yahee-copy" }, z = /* @__PURE__ */ l({
15
15
  message: { default: "复制成功" }
16
16
  },
17
17
  setup(c) {
18
- const s = c, { copyUrl: r } = y(), p = () => {
19
- r(s.content), _({
18
+ const s = c, { copyUrl: p } = _(), r = () => {
19
+ p(s.content), y({
20
20
  message: s.message,
21
21
  type: "success"
22
22
  });
23
23
  };
24
- return (n, g) => (m(), a("div", C, [
24
+ return (n, g) => (m(), l("div", C, [
25
25
  e(o(u), {
26
26
  placement: "right",
27
27
  effect: "light",
28
28
  offset: -5,
29
29
  "show-arrow": !1,
30
- "popper-class": "custom-popper-class"
30
+ "popper-class": "yahee-copy-custom-popper-class"
31
31
  }, {
32
32
  content: t(() => [
33
33
  e(o(d), {
34
34
  color: "#3366cc",
35
35
  size: "18",
36
36
  class: "icon",
37
- onClick: p
37
+ onClick: r
38
38
  }, {
39
39
  default: t(() => [
40
40
  e(o(h))
@@ -1,7 +1,12 @@
1
- .yahee-copy .custom-popper-class {
1
+ .yahee-copy .el-tooltip__trigger {
2
+ width: -moz-fit-content !important;
3
+ width: fit-content !important;
4
+ }
5
+
6
+ .yahee-copy-custom-popper-class {
2
7
  background: transparent !important;
3
8
  border: none !important;
4
9
  }
5
- .yahee-copy .custom-popper-class .icon {
10
+ .yahee-copy-custom-popper-class .icon {
6
11
  cursor: pointer;
7
12
  }
package/es/style.css CHANGED
@@ -3,11 +3,16 @@
3
3
  border: 1px solid red;
4
4
  }
5
5
 
6
- .yahee-copy .custom-popper-class {
6
+ .yahee-copy .el-tooltip__trigger {
7
+ width: -moz-fit-content !important;
8
+ width: fit-content !important;
9
+ }
10
+
11
+ .yahee-copy-custom-popper-class {
7
12
  background: transparent !important;
8
13
  border: none !important;
9
14
  }
10
- .yahee-copy .custom-popper-class .icon {
15
+ .yahee-copy-custom-popper-class .icon {
11
16
  cursor: pointer;
12
17
  }
13
18
 
@@ -1,7 +1,12 @@
1
- .yahee-copy .custom-popper-class {
1
+ .yahee-copy .el-tooltip__trigger {
2
+ width: -moz-fit-content !important;
3
+ width: fit-content !important;
4
+ }
5
+
6
+ .yahee-copy-custom-popper-class {
2
7
  background: transparent !important;
3
8
  border: none !important;
4
9
  }
5
- .yahee-copy .custom-popper-class .icon {
10
+ .yahee-copy-custom-popper-class .icon {
6
11
  cursor: pointer;
7
12
  }
package/lib/style.css CHANGED
@@ -3,11 +3,16 @@
3
3
  border: 1px solid red;
4
4
  }
5
5
 
6
- .yahee-copy .custom-popper-class {
6
+ .yahee-copy .el-tooltip__trigger {
7
+ width: -moz-fit-content !important;
8
+ width: fit-content !important;
9
+ }
10
+
11
+ .yahee-copy-custom-popper-class {
7
12
  background: transparent !important;
8
13
  border: none !important;
9
14
  }
10
- .yahee-copy .custom-popper-class .icon {
15
+ .yahee-copy-custom-popper-class .icon {
11
16
  cursor: pointer;
12
17
  }
13
18
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "yahee-components",
3
3
  "private": false,
4
- "version": "0.0.64",
4
+ "version": "0.0.65",
5
5
  "description": "深圳前海亚讯前端组件库",
6
6
  "main": "lib",
7
7
  "module": "es",
@@ -1,12 +1,2 @@
1
1
  import { default as copy } from './copy.vue';
2
- /**
3
- * 定义props类型
4
- */
5
- export interface CopyProps {
6
- content: string;
7
- message?: string;
8
- }
9
- /**
10
- * 定义instance类型
11
- */
12
2
  export type CopyInstance = InstanceType<typeof copy>;
@@ -1,4 +1,4 @@
1
- import { CopyProps } from './copy';
1
+ import { CopyProps } from './props';
2
2
  import { DefineComponent, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
3
3
  declare function __VLS_template(): {
4
4
  attrs: Partial<{}>;
@@ -1,6 +1,6 @@
1
1
  import { SFCWithInstall } from '../utils/typescript';
2
2
  import { CreateComponentPublicInstanceWithMixins, ComponentOptionsMixin, PublicProps, GlobalComponents, GlobalDirectives, ComponentProvideOptions, ComponentOptionsBase, VNodeProps, AllowedComponentProps, ComponentCustomProps } from 'vue';
3
- import { CopyProps } from './copy';
3
+ import { CopyProps } from './props';
4
4
  export declare const YaheeCopy: SFCWithInstall<{
5
5
  new (...args: any[]): CreateComponentPublicInstanceWithMixins<Readonly< CopyProps> & Readonly<{}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, PublicProps, {
6
6
  message: string;
@@ -29,4 +29,5 @@ export declare const YaheeCopy: SFCWithInstall<{
29
29
  })> & Record<string, any>;
30
30
  export default YaheeCopy;
31
31
  export * from './copy.vue';
32
+ export * from './props';
32
33
  export * from './copy';
@@ -0,0 +1,7 @@
1
+ /**
2
+ * 定义props类型
3
+ */
4
+ export interface CopyProps {
5
+ content: string;
6
+ message?: string;
7
+ }