@fangzhongya/fang-ui 0.0.18 → 0.0.20

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.
Files changed (81) hide show
  1. package/dist/components/array/index.ts +1 -1
  2. package/dist/components/array/{index.scss → style/index.scss} +1 -1
  3. package/dist/components/box/index.ts +1 -1
  4. package/dist/components/box/{index.scss → style/index.scss} +3 -3
  5. package/dist/components/box-adjust/index.ts +1 -1
  6. package/dist/components/box-adjust/{index.scss → style/index.scss} +3 -3
  7. package/dist/components/box-local/index.ts +1 -1
  8. package/dist/components/box-local/style/index.scss +7 -0
  9. package/dist/components/box-mask/index.ts +1 -1
  10. package/dist/components/box-mask/{index.scss → style/index.scss} +1 -1
  11. package/dist/components/box-title/index.ts +1 -1
  12. package/dist/components/box-title/{index.scss → style/index.scss} +1 -1
  13. package/dist/components/buttons/index.ts +1 -1
  14. package/dist/components/buttons/{index.scss → style/index.scss} +1 -1
  15. package/dist/components/cascaders/index.ts +1 -1
  16. package/dist/components/cascaders/{index.scss → style/index.scss} +1 -1
  17. package/dist/components/checks/index.ts +1 -1
  18. package/dist/components/checks/{index.scss → style/index.scss} +1 -1
  19. package/dist/components/cs-i18n/src/index.cjs +4 -8
  20. package/dist/components/cs-i18n/src/index.js +3 -7
  21. package/dist/components/cs-i18n/src/index.vue +2 -6
  22. package/dist/components/dates/index.ts +1 -1
  23. package/dist/components/dates/{index.scss → style/index.scss} +1 -1
  24. package/dist/components/dialog/index.ts +1 -1
  25. package/dist/components/dialog/{index.scss → style/index.scss} +1 -1
  26. package/dist/components/drawer/index.ts +1 -1
  27. package/dist/components/drawer/style/cs.scss +2 -2
  28. package/dist/components/drawer/{index.scss → style/index.scss} +4 -4
  29. package/dist/components/el-tables/index.ts +1 -1
  30. package/dist/components/el-tables/{index.scss → style/index.scss} +1 -1
  31. package/dist/components/forms/index.ts +1 -1
  32. package/dist/components/forms/{index.scss → style/index.scss} +3 -3
  33. package/dist/components/forms-div/index.ts +1 -1
  34. package/dist/components/forms-div/{index.scss → style/index.scss} +1 -1
  35. package/dist/components/forms-item/index.ts +1 -1
  36. package/dist/components/forms-item/{index.scss → style/index.scss} +2 -2
  37. package/dist/components/forms-items/index.ts +1 -1
  38. package/dist/components/forms-items/style/index.scss +2 -0
  39. package/dist/components/global-config/index.ts +1 -1
  40. package/dist/components/global-config/{index.scss → style/index.scss} +2 -2
  41. package/dist/components/index.scss +31 -31
  42. package/dist/components/input-array/index.ts +1 -1
  43. package/dist/components/input-array/{index.scss → style/index.scss} +1 -1
  44. package/dist/components/input-num/index.ts +1 -1
  45. package/dist/components/input-num/{index.scss → style/index.scss} +1 -1
  46. package/dist/components/inputs/index.ts +1 -1
  47. package/dist/components/inputs/{index.scss → style/index.scss} +1 -1
  48. package/dist/components/lists/index.ts +1 -1
  49. package/dist/components/lists/{index.scss → style/index.scss} +1 -1
  50. package/dist/components/page/index.ts +1 -1
  51. package/dist/components/page/{index.scss → style/index.scss} +1 -1
  52. package/dist/components/pagin/index.ts +1 -1
  53. package/dist/components/pagin/src/index.cjs +1 -1
  54. package/dist/components/pagin/src/index.js +1 -1
  55. package/dist/components/pagin/src/index.vue +2 -2
  56. package/dist/components/pagin/{index.scss → style/index.scss} +1 -1
  57. package/dist/components/popup/index.ts +1 -1
  58. package/dist/components/popup/{index.scss → style/index.scss} +3 -3
  59. package/dist/components/selects/index.ts +1 -1
  60. package/dist/components/selects/{index.scss → style/index.scss} +1 -1
  61. package/dist/components/switchs/index.ts +1 -1
  62. package/dist/components/switchs/{index.scss → style/index.scss} +1 -1
  63. package/dist/components/tables/index.ts +1 -1
  64. package/dist/components/tables/{index.scss → style/index.scss} +1 -1
  65. package/dist/components/tables-pagin/index.ts +1 -1
  66. package/dist/components/tables-pagin/{index.scss → style/index.scss} +3 -3
  67. package/dist/components/text/index.ts +1 -1
  68. package/dist/components/text/style/index.scss +5 -0
  69. package/dist/components/vxe-tables/index.ts +1 -1
  70. package/dist/components/vxe-tables/{index.scss → style/index.scss} +1 -1
  71. package/dist/components/window/index.ts +1 -1
  72. package/dist/components/window/{index.scss → style/index.scss} +3 -3
  73. package/dist/hooks/global-config/index.cjs +1 -1
  74. package/dist/hooks/global-config/index.d.ts +4 -1
  75. package/dist/hooks/global-config/index.js +1 -1
  76. package/dist/hooks/global-config/index.ts +20 -9
  77. package/package.json +2 -2
  78. package/dist/components/box-local/index.scss +0 -7
  79. package/dist/components/forms-items/index.scss +0 -2
  80. package/dist/components/text/index.scss +0 -5
  81. /package/dist/components/{forms-items → forms-item}/index.css +0 -0
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const Array = withInstall(SrcVue, 'Array');
@@ -1,4 +1,4 @@
1
- @use '../css/common.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
2
 
3
3
  $array: 'array';
4
4
  @include b($array) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const Box = withInstall(SrcVue, 'Box');
@@ -1,10 +1,10 @@
1
- @use '../css/common.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
2
 
3
3
  // @use '../../box-mask/src/index.scss' as *;
4
- @use '../box-title/index.scss' as *;
4
+ @use '../../box-title/style/index.scss' as *;
5
5
 
6
6
  // @use '@components/css/common.scss' as *;
7
- @use '../box-mask/index.scss' as *;
7
+ @use '../../box-mask/style/index.scss' as *;
8
8
  // @use '@components/box-title/style/index.scss' as *;
9
9
 
10
10
  $box: 'box';
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const BoxAdjust = withInstall(SrcVue, 'BoxAdjust');
@@ -3,9 +3,9 @@
3
3
  // @use '../../box-mask/src/index.scss' as *;
4
4
  // @use '../../box-title/src/index.scss' as *;
5
5
 
6
- @use '../css/common.scss' as *;
7
- @use '../box-mask/index.scss' as *;
8
- @use '../box-title/index.scss' as *;
6
+ @use '../../css/common.scss' as *;
7
+ @use '../../box-mask/style/index.scss' as *;
8
+ @use '../../box-title/style/index.scss' as *;
9
9
 
10
10
  $box-adjust: 'box-adjust';
11
11
  @include b($box-adjust) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const BoxLocal = withInstall(SrcVue, 'BoxLocal');
@@ -0,0 +1,7 @@
1
+ @use '../../css/common.scss' as *;
2
+ @use '../../box/style/index.scss' as *;
3
+
4
+ $box-local: 'box-local';
5
+ @include b($box-local) {
6
+ text-align: left;
7
+ }
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const BoxMask = withInstall(SrcVue, 'BoxMask');
@@ -1,5 +1,5 @@
1
1
  // @use '../../../common.scss' as *;
2
- @use '../css/common.scss' as *;
2
+ @use '../../css/common.scss' as *;
3
3
 
4
4
  $box-mask: 'box-mask';
5
5
  @include b($box-mask) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const BoxTitle = withInstall(SrcVue, 'BoxTitle');
@@ -1,5 +1,5 @@
1
1
  // @use '../../../common.scss' as *;
2
- @use '../css/common.scss' as *;
2
+ @use '../../css/common.scss' as *;
3
3
 
4
4
  $box-title: 'box-title';
5
5
  @include b($box-title) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const Buttons = withInstall(SrcVue, 'Buttons');
@@ -1,4 +1,4 @@
1
- @use '../css/common.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
2
 
3
3
  $buttons: 'buttons';
4
4
  @include b($buttons) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const Cascaders = withInstall(SrcVue, 'Cascaders');
@@ -1,4 +1,4 @@
1
- @use '../css/common.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
2
 
3
3
  $cascaders: 'cascaders';
4
4
  @include b($cascaders) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const Checks = withInstall(SrcVue, 'Checks');
@@ -1,4 +1,4 @@
1
- @use '../css/common.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
2
 
3
3
  $checks: 'checks';
4
4
  @include b($checks) {
@@ -2,7 +2,7 @@
2
2
  Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
3
3
  const vue = require("vue");
4
4
  const data = require("./data.cjs");
5
- const index$2 = require("../../../locale/index.cjs");
5
+ const index$1 = require("../../../locale/index.cjs");
6
6
  require("@fangzhongya/utils/basic/string/splitUpper");
7
7
  require("@fangzhongya/utils/basic/array/isArray");
8
8
  require("@fangzhongya/utils/basic/object/isObject");
@@ -15,7 +15,7 @@ require("@fangzhongya/utils/name/humpToLine");
15
15
  require("@fangzhongya/utils/basic/object/deepCopy");
16
16
  require("@fangzhongya/utils/basic/Array/toggleArray");
17
17
  require("@fangzhongya/utils/basic/object/objValue");
18
- const index$1 = require("../../../hooks/global-config/index.cjs");
18
+ const index$2 = require("../../../hooks/global-config/index.cjs");
19
19
  const index = require("../../../hooks/cssname/index.cjs");
20
20
  const _hoisted_1 = ["onClick"];
21
21
  const _sfc_main = /* @__PURE__ */ vue.defineComponent({
@@ -23,16 +23,12 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
23
23
  props: data.dataProps,
24
24
  setup(__props) {
25
25
  const cs = index.useCssName("cs-i18n");
26
- const config = index$1.useGlobalConfig();
27
- const objconfig = vue.unref(config) || {};
28
- const comlocales = index$2;
26
+ const comlocales = index$1;
29
27
  const props = __props;
30
28
  const list = Object.entries(comlocales.Common.value);
31
29
  function onClick(item) {
32
30
  const mc = lineToLargeHump.lineToLargeHump(item[0]);
33
- objconfig.locale = comlocales[mc];
34
- objconfig.cssname = item[0];
35
- index$1.setGlobalConfig(objconfig);
31
+ index$2.setGlobalConfig(mc, "locale");
36
32
  }
37
33
  return (_ctx, _cache) => {
38
34
  return vue.openBlock(), vue.createElementBlock("div", {
@@ -1,4 +1,4 @@
1
- import { defineComponent, unref, createElementBlock, openBlock, normalizeClass, Fragment, renderList, createElementVNode, withModifiers, toDisplayString } from "vue";
1
+ import { defineComponent, createElementBlock, openBlock, normalizeClass, unref, Fragment, renderList, createElementVNode, withModifiers, toDisplayString } from "vue";
2
2
  import { dataProps } from "./data.js";
3
3
  import * as index from "../../../locale/index.js";
4
4
  import "@fangzhongya/utils/basic/string/splitUpper";
@@ -13,7 +13,7 @@ import "@fangzhongya/utils/name/humpToLine";
13
13
  import "@fangzhongya/utils/basic/object/deepCopy";
14
14
  import "@fangzhongya/utils/basic/Array/toggleArray";
15
15
  import "@fangzhongya/utils/basic/object/objValue";
16
- import { useGlobalConfig, setGlobalConfig } from "../../../hooks/global-config/index.js";
16
+ import { setGlobalConfig } from "../../../hooks/global-config/index.js";
17
17
  import { useCssName } from "../../../hooks/cssname/index.js";
18
18
  const _hoisted_1 = ["onClick"];
19
19
  const _sfc_main = /* @__PURE__ */ defineComponent({
@@ -21,16 +21,12 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
21
21
  props: dataProps,
22
22
  setup(__props) {
23
23
  const cs = useCssName("cs-i18n");
24
- const config = useGlobalConfig();
25
- const objconfig = unref(config) || {};
26
24
  const comlocales = index;
27
25
  const props = __props;
28
26
  const list = Object.entries(comlocales.Common.value);
29
27
  function onClick(item) {
30
28
  const mc = lineToLargeHump(item[0]);
31
- objconfig.locale = comlocales[mc];
32
- objconfig.cssname = item[0];
33
- setGlobalConfig(objconfig);
29
+ setGlobalConfig(mc, "locale");
34
30
  }
35
31
  return (_ctx, _cache) => {
36
32
  return openBlock(), createElementBlock("div", {
@@ -19,11 +19,9 @@
19
19
  import * as locale from '../../../locale/index';
20
20
  import type { Locale } from '../../../types/locale';
21
21
  import { lineToLargeHump } from '../../../utils/util';
22
- import { useGlobalConfig, setGlobalConfig } from '../../../hooks/global-config';
22
+ import { setGlobalConfig } from '../../../hooks/global-config';
23
23
  import { useCssName } from '../../../hooks/cssname';
24
24
  const cs = useCssName('cs-i18n');
25
- const config = useGlobalConfig();
26
- const objconfig = unref(config) || {};
27
25
 
28
26
  const comlocales: {
29
27
  [key: string]: Locale;
@@ -34,9 +32,7 @@
34
32
 
35
33
  function onClick(item: [string, string]) {
36
34
  const mc = lineToLargeHump(item[0]);
37
- objconfig.locale = comlocales[mc];
38
- objconfig.cssname = item[0];
39
- setGlobalConfig(objconfig);
35
+ setGlobalConfig(mc, 'locale');
40
36
  }
41
37
  </script>
42
38
  <style lang="scss"></style>
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const Dates = withInstall(SrcVue, 'Dates');
@@ -1,4 +1,4 @@
1
- @use '../css/common.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
2
 
3
3
  $dates: 'dates';
4
4
  @include b($dates) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const Dialog = withInstall(SrcVue, 'Dialog');
@@ -1,4 +1,4 @@
1
- @use '../css/common.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
2
 
3
3
  $dialog: 'f-dialog';
4
4
  @include b($dialog) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const Drawer = withInstall(SrcVue, 'Drawer');
@@ -4,8 +4,8 @@
4
4
  // @use '../../../../frame/box-title/src/index.scss' as *;
5
5
 
6
6
  @use '../../css/common.scss' as *;
7
- @use '../../box-mask/index.scss' as *;
8
- @use '../../box-title/index.scss' as *;
7
+ @use '../../box-mask/style/index.scss' as *;
8
+ @use '../../box-title/style/index.scss' as *;
9
9
 
10
10
  .cs {
11
11
  text-align: center;
@@ -2,11 +2,11 @@
2
2
 
3
3
  // @use '../../../../frame/box-mask/src/index.scss' as *;
4
4
  // @use '../../../../frame/box-title/src/index.scss' as *;
5
- @use './style/cs.scss' as *;
5
+ @use './cs.scss' as *;
6
6
 
7
- @use '../css/common.scss' as *;
8
- @use '../box-mask/index.scss' as *;
9
- @use '../box-title/index.scss' as *;
7
+ @use '../../css/common.scss' as *;
8
+ @use '../../box-mask/style/index.scss' as *;
9
+ @use '../../box-title/style/index.scss' as *;
10
10
 
11
11
  .#{e()}drawer {
12
12
  margin: 10px;
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const ElTables = withInstall(SrcVue, 'ElTables');
@@ -1,4 +1,4 @@
1
- @use '../css/common.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
2
 
3
3
  $tables: 'tables';
4
4
  @include b($tables) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const Forms = withInstall(SrcVue, 'Forms');
@@ -1,6 +1,6 @@
1
- @use '../css/common.scss' as *;
2
- @use '../forms-div/index.scss' as *;
3
- @use '../forms-item/index.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
+ @use '../../forms-div/style/index.scss' as *;
3
+ @use '../../forms-item/style/index.scss' as *;
4
4
 
5
5
  $forms: 'forms';
6
6
  @include b($forms) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const FormsDiv = withInstall(SrcVue, 'FormsDiv');
@@ -1,4 +1,4 @@
1
- @use '../css/common.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
2
 
3
3
  $forms-div: 'forms-div';
4
4
  @include b($forms-div) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const FormsItem = withInstall(SrcVue, 'FormsItem');
@@ -1,5 +1,5 @@
1
- @use '../css/common.scss' as *;
2
- @use '../forms-div/index.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
+ @use '../../forms-div/style/index.scss' as *;
3
3
  $forms-item: 'forms-item';
4
4
  @include b($forms-item) {
5
5
  width: 100%;
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const FormsItems = withInstall(SrcVue, 'FormsItems');
@@ -0,0 +1,2 @@
1
+ @use '../../forms-div/style/index.scss' as *;
2
+ @use '../../forms-item/style/index.scss' as *;
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index'
4
4
  const GlobalConfig = withInstall(SrcVue, 'GlobalConfig');
@@ -2,8 +2,8 @@
2
2
 
3
3
  // @use '../../element/feedback/drawer/src/index.scss' as *;
4
4
 
5
- @use '../css/common.scss' as *;
6
- @use '../drawer/index.scss' as *;
5
+ @use '../../css/common.scss' as *;
6
+ @use '../../drawer/style/index.scss' as *;
7
7
 
8
8
  .#{$namespace}global-config {
9
9
  left: 0;
@@ -1,31 +1,31 @@
1
- @use './dialog/index.scss' as *;
2
- @use './drawer/index.scss' as *;
3
- @use './forms-div/index.scss' as *;
4
- @use './forms-item/index.scss' as *;
5
- @use './forms-items/index.scss' as *;
6
- @use './forms/index.scss' as *;
7
- @use './box-adjust/index.scss' as *;
8
- @use './box-local/index.scss' as *;
9
- @use './box-mask/index.scss' as *;
10
- @use './box-title/index.scss' as *;
11
- @use './box/index.scss' as *;
12
- @use './popup/index.scss' as *;
13
- @use './window/index.scss' as *;
14
- @use './global-config/index.scss' as *;
15
- @use './lists/index.scss' as *;
16
- @use './page/index.scss' as *;
17
- @use './array/index.scss' as *;
18
- @use './buttons/index.scss' as *;
19
- @use './cascaders/index.scss' as *;
20
- @use './checks/index.scss' as *;
21
- @use './dates/index.scss' as *;
22
- @use './input-array/index.scss' as *;
23
- @use './input-num/index.scss' as *;
24
- @use './inputs/index.scss' as *;
25
- @use './selects/index.scss' as *;
26
- @use './switchs/index.scss' as *;
27
- @use './text/index.scss' as *;
28
- @use './el-tables/index.scss' as *;
29
- @use './pagin/index.scss' as *;
30
- @use './tables-pagin/index.scss' as *;
31
- @use './tables/index.scss' as *;
1
+ @use './dialog/style/index.scss' as *;
2
+ @use './drawer/style/index.scss' as *;
3
+ @use './forms-div/style/index.scss' as *;
4
+ @use './forms-item/style/index.scss' as *;
5
+ @use './forms-items/style/index.scss' as *;
6
+ @use './forms/style/index.scss' as *;
7
+ @use './box-adjust/style/index.scss' as *;
8
+ @use './box-local/style/index.scss' as *;
9
+ @use './box-mask/style/index.scss' as *;
10
+ @use './box-title/style/index.scss' as *;
11
+ @use './box/style/index.scss' as *;
12
+ @use './popup/style/index.scss' as *;
13
+ @use './window/style/index.scss' as *;
14
+ @use './global-config/style/index.scss' as *;
15
+ @use './lists/style/index.scss' as *;
16
+ @use './page/style/index.scss' as *;
17
+ @use './array/style/index.scss' as *;
18
+ @use './buttons/style/index.scss' as *;
19
+ @use './cascaders/style/index.scss' as *;
20
+ @use './checks/style/index.scss' as *;
21
+ @use './dates/style/index.scss' as *;
22
+ @use './input-array/style/index.scss' as *;
23
+ @use './input-num/style/index.scss' as *;
24
+ @use './inputs/style/index.scss' as *;
25
+ @use './selects/style/index.scss' as *;
26
+ @use './switchs/style/index.scss' as *;
27
+ @use './text/style/index.scss' as *;
28
+ @use './el-tables/style/index.scss' as *;
29
+ @use './pagin/style/index.scss' as *;
30
+ @use './tables-pagin/style/index.scss' as *;
31
+ @use './tables/style/index.scss' as *;
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const InputArray = withInstall(SrcVue, 'InputArray');
@@ -1,4 +1,4 @@
1
- @use '../css/common.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
2
 
3
3
  $input-array: 'input-array';
4
4
  @include b($input-array) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const InputNum = withInstall(SrcVue, 'InputNum');
@@ -1,4 +1,4 @@
1
- @use '../css/common.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
2
 
3
3
  $input-num: 'input-num';
4
4
  @include b($input-num) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const Inputs = withInstall(SrcVue, 'Inputs');
@@ -1,4 +1,4 @@
1
- @use '../css/common.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
2
 
3
3
  $inputs: 'inputs';
4
4
  @include b($inputs) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const Lists = withInstall(SrcVue, 'Lists');
@@ -1,4 +1,4 @@
1
- @use '../css/common.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
2
 
3
3
  $lists: 'lists';
4
4
  @include b($lists) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const Page = withInstall(SrcVue, 'Page');
@@ -1,4 +1,4 @@
1
- @use '../css/common.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
2
 
3
3
  $page: 'page';
4
4
  @include b($page) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const Pagin = withInstall(SrcVue, 'Pagin');
@@ -40,7 +40,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
40
40
  if (props.total && props.paginat.pageSize) {
41
41
  v = Math.ceil(props.total / props.paginat.pageSize);
42
42
  }
43
- return "当前第" + props.paginat.current + "页ss共" + v + "页ss每页" + props.paginat.pageSize + "条记录";
43
+ return "当前第" + props.paginat.current + "页 共" + v + "页 每页" + props.paginat.pageSize + "条记录";
44
44
  };
45
45
  const onCurrentChange = (v) => {
46
46
  console.log("current", v);
@@ -38,7 +38,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
38
38
  if (props.total && props.paginat.pageSize) {
39
39
  v = Math.ceil(props.total / props.paginat.pageSize);
40
40
  }
41
- return "当前第" + props.paginat.current + "页ss共" + v + "页ss每页" + props.paginat.pageSize + "条记录";
41
+ return "当前第" + props.paginat.current + "页 共" + v + "页 每页" + props.paginat.pageSize + "条记录";
42
42
  };
43
43
  const onCurrentChange = (v) => {
44
44
  console.log("current", v);
@@ -40,9 +40,9 @@
40
40
  return (
41
41
  '当前第' +
42
42
  props.paginat.current +
43
- '页\s\s共' +
43
+ '共' +
44
44
  v +
45
- '页\s\s每页' +
45
+ '每页' +
46
46
  props.paginat.pageSize +
47
47
  '条记录'
48
48
  );
@@ -1,4 +1,4 @@
1
- @use '../css/common.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
2
 
3
3
  $pags: 'pags';
4
4
  @include b($pags) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const Popup = withInstall(SrcVue, 'Popup');
@@ -3,9 +3,9 @@
3
3
  // @use '../../box-mask/src/index.scss' as *;
4
4
  // @use '../../box-title/src/index.scss' as *;
5
5
 
6
- @use '../css/common.scss' as *;
7
- @use '../box-mask/index.scss' as *;
8
- @use '../box-title/index.scss' as *;
6
+ @use '../../css/common.scss' as *;
7
+ @use '../../box-mask/style/index.scss' as *;
8
+ @use '../../box-title/style/index.scss' as *;
9
9
 
10
10
  $popup: 'popup';
11
11
  @include b($popup) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const Selects = withInstall(SrcVue, 'Selects');
@@ -1,4 +1,4 @@
1
- @use '../css/common.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
2
 
3
3
  $selects: 'selects';
4
4
  @include b($selects) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const Switchs = withInstall(SrcVue, 'Switchs');
@@ -1,4 +1,4 @@
1
- @use '../css/common.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
2
 
3
3
  $switchs: 'switchs';
4
4
  @include b($switchs) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const Tables = withInstall(SrcVue, 'Tables');
@@ -1,4 +1,4 @@
1
- @use '../css/common.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
2
 
3
3
  $tables-pag: 'tables-pag';
4
4
  @include b($tables-pag) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const TablesPagin = withInstall(SrcVue, 'TablesPagin');
@@ -1,6 +1,6 @@
1
- @use '../css/common.scss' as *;
2
- @use '../el-tables/index.scss' as *;
3
- @use '../pagin/index.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
+ @use '../../el-tables/style/index.scss' as *;
3
+ @use '../../pagin/style/index.scss' as *;
4
4
  $tables-pagin: 'tables-pagin';
5
5
  @include b($tables-pagin) {
6
6
  width: 100%;
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const Text = withInstall(SrcVue, 'Text');
@@ -0,0 +1,5 @@
1
+ @use '../../css/common.scss' as *;
2
+
3
+ $text: 'text';
4
+ @include b($text) {
5
+ }
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const VxeTables = withInstall(SrcVue, 'VxeTables');
@@ -1,4 +1,4 @@
1
- @use '../css/common.scss' as *;
1
+ @use '../../css/common.scss' as *;
2
2
 
3
3
  $vtables: 'vtables';
4
4
  @include b($vtables) {
@@ -1,4 +1,4 @@
1
- import './index.scss';
1
+ import './style/index.scss';
2
2
  import { withInstall } from '../../utils/vues/withInstall'
3
3
  import SrcVue from './src/index.vue'
4
4
  const Window = withInstall(SrcVue, 'Window');
@@ -3,9 +3,9 @@
3
3
  // @use '../../box-mask/src/index.scss' as *;
4
4
  // @use '../../box-title/src/index.scss' as *;
5
5
 
6
- @use '../css/common.scss' as *;
7
- @use '../box-mask/index.scss' as *;
8
- @use '../box-title/index.scss' as *;
6
+ @use '../../css/common.scss' as *;
7
+ @use '../../box-mask/style/index.scss' as *;
8
+ @use '../../box-title/style/index.scss' as *;
9
9
 
10
10
  $window: 'window';
11
11
  @include b($window) {
@@ -18,7 +18,7 @@ function useGlobalConfig(key, defaultValue) {
18
18
  }
19
19
  function setGlobalConfig(obj, key) {
20
20
  {
21
- globalConfig.value = obj;
21
+ globalConfig.value[key] = obj;
22
22
  }
23
23
  }
24
24
  function provideGlobalConfig(config, app, global = false) {
@@ -3,5 +3,8 @@ import { MaybeRef } from '../../types/hooks';
3
3
  import { DataProps } from '../../components/global-config/src/data';
4
4
  export declare function useGlobalConfig<K extends keyof DataProps, D extends DataProps[K]>(key: K, defaultValue?: D): Ref<Exclude<DataProps[K], undefined> | D>;
5
5
  export declare function useGlobalConfig(): Ref<DataProps>;
6
- export declare function setGlobalConfig(obj: DataProps | DataProps[keyof DataProps], key?: keyof DataProps): void;
6
+ type V = DataProps | DataProps[keyof DataProps];
7
+ type K = keyof DataProps;
8
+ export declare function setGlobalConfig(obj: V, key: K): void;
7
9
  export declare function provideGlobalConfig(config: MaybeRef<DataProps>, app?: App, global?: boolean): ComputedRef<Readonly<DataProps>>;
10
+ export {};
@@ -16,7 +16,7 @@ function useGlobalConfig(key, defaultValue) {
16
16
  }
17
17
  function setGlobalConfig(obj, key) {
18
18
  {
19
- globalConfig.value = obj;
19
+ globalConfig.value[key] = obj;
20
20
  }
21
21
  }
22
22
  function provideGlobalConfig(config, app, global = false) {
@@ -34,17 +34,28 @@ function setValue<T>(v: T[keyof T], k: keyof T, z: T): T {
34
34
  z[k] = v;
35
35
  return z;
36
36
  }
37
+ // 代码打包有问题
38
+ // export function setGlobalConfig(
39
+ // obj: DataProps | DataProps[keyof DataProps],
40
+ // key?: keyof DataProps,
41
+ // ) {
42
+ // if (key) {
43
+ // globalConfig.value = setValue(
44
+ // obj as DataProps[keyof DataProps],
45
+ // key,
46
+ // globalConfig.value,
47
+ // );
48
+ // } else {
49
+ // globalConfig.value = obj as DataProps;
50
+ // }
51
+ // }
37
52
 
38
- export function setGlobalConfig(
39
- obj: DataProps | DataProps[keyof DataProps],
40
- key?: keyof DataProps,
41
- ) {
53
+ type V = DataProps | DataProps[keyof DataProps];
54
+ type K = keyof DataProps;
55
+
56
+ export function setGlobalConfig(obj: V, key: K) {
42
57
  if (key) {
43
- globalConfig.value = setValue(
44
- obj as DataProps[keyof DataProps],
45
- key,
46
- globalConfig.value,
47
- );
58
+ globalConfig.value[key] = obj as any;
48
59
  } else {
49
60
  globalConfig.value = obj as DataProps;
50
61
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@fangzhongya/fang-ui",
3
3
  "private": false,
4
- "version": "0.0.18",
4
+ "version": "0.0.20",
5
5
  "type": "module",
6
6
  "description ": "fang-ui",
7
7
  "keywords": [
@@ -47,8 +47,8 @@
47
47
  "vue-tsc": "^3.0.3",
48
48
  "vuedraggable": "4.1.0",
49
49
  "vxe-table": "4.14.4",
50
- "@fang-ui/components": "0.0.1-0",
51
50
  "@fang-ui/directives": "0.0.1-0",
51
+ "@fang-ui/components": "0.0.1-0",
52
52
  "@fang-ui/hooks": "0.0.1-0",
53
53
  "@fang-ui/icons": "0.0.1-0",
54
54
  "@fang-ui/locale": "0.0.1-0",
@@ -1,7 +0,0 @@
1
- @use '../css/common.scss' as *;
2
- @use '../box/index.scss' as *;
3
-
4
- $box-local: 'box-local';
5
- @include b($box-local) {
6
- text-align: left;
7
- }
@@ -1,2 +0,0 @@
1
- @use '../forms-div/index.scss' as *;
2
- @use '../forms-item/index.scss' as *;
@@ -1,5 +0,0 @@
1
- @use '../css/common.scss' as *;
2
-
3
- $text: 'text';
4
- @include b($text) {
5
- }