rx-compo 1.0.53 → 1.0.54

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 (75) hide show
  1. package/entry/types/index.d.ts +0 -1
  2. package/es/components/RxButton/index.js +16 -25
  3. package/es/components/RxCheckbox/index.js +3712 -0
  4. package/es/components/RxCheckboxGroup/index.js +6430 -0
  5. package/es/components/RxDatePicker/index.js +13042 -0
  6. package/es/components/RxInput/index.js +1560 -0
  7. package/es/components/RxOption/index.js +8859 -0
  8. package/es/components/RxRadio/index.js +646 -0
  9. package/es/components/RxRadioButton/index.js +646 -0
  10. package/es/components/RxRadioGroup/index.js +1117 -0
  11. package/es/components/RxScrollbar/index.js +867 -0
  12. package/es/components/RxSelect/index.js +9022 -0
  13. package/es/components/RxSelectPlus/index.js +17471 -0
  14. package/es/components/RxSuperCondition/index.js +8690 -0
  15. package/es/components/RxTooltip/index.js +2470 -0
  16. package/es/components/index.js +13 -0
  17. package/es/index.d.ts +0 -1
  18. package/es/index.js +0 -1
  19. package/es/utils/useContext.d.ts +10 -0
  20. package/es/utils/useContext.js +13 -0
  21. package/es/utils/useTextOverflow.d.ts +4 -0
  22. package/es/utils/useTextOverflow.js +13 -0
  23. package/es/utils/with-install.d.ts +2 -2
  24. package/index.esm.js +43171 -1577
  25. package/index.js +43192 -1585
  26. package/lib/components/RxButton/index.js +15 -24
  27. package/lib/components/RxCheckbox/index.js +3717 -0
  28. package/lib/components/RxCheckboxGroup/index.js +6435 -0
  29. package/lib/components/RxDatePicker/index.js +13047 -0
  30. package/lib/components/RxInput/index.js +1565 -0
  31. package/lib/components/RxOption/index.js +8864 -0
  32. package/lib/components/RxRadio/index.js +651 -0
  33. package/lib/components/RxRadioButton/index.js +651 -0
  34. package/lib/components/RxRadioGroup/index.js +1122 -0
  35. package/lib/components/RxScrollbar/index.js +872 -0
  36. package/lib/components/RxSelect/index.js +9027 -0
  37. package/lib/components/RxSelectPlus/index.js +17476 -0
  38. package/lib/components/RxSuperCondition/index.js +8695 -0
  39. package/lib/components/RxTooltip/index.js +2475 -0
  40. package/lib/components/index.js +91 -0
  41. package/lib/index.d.ts +0 -1
  42. package/lib/index.js +0 -1
  43. package/lib/utils/useContext.d.ts +10 -0
  44. package/lib/utils/useContext.js +18 -0
  45. package/lib/utils/useTextOverflow.d.ts +4 -0
  46. package/lib/utils/useTextOverflow.js +17 -0
  47. package/lib/utils/with-install.d.ts +2 -2
  48. package/package.json +4 -2
  49. package/theme-chalk/css/index.css +1 -1
  50. package/theme-chalk/css/rx-button.css +1 -0
  51. package/theme-chalk/css/rx-checkbox-group.css +1 -0
  52. package/theme-chalk/css/rx-checkbox.css +1 -0
  53. package/theme-chalk/css/rx-date-picker.css +0 -0
  54. package/theme-chalk/css/rx-input.css +1 -0
  55. package/theme-chalk/css/rx-option.css +1 -0
  56. package/theme-chalk/css/rx-radio-button.css +0 -0
  57. package/theme-chalk/css/rx-radio-group.css +1 -0
  58. package/theme-chalk/css/rx-radio.css +1 -0
  59. package/theme-chalk/css/rx-scrollbar.css +0 -0
  60. package/theme-chalk/css/rx-select.css +1 -0
  61. package/theme-chalk/css/rx-super-condition.css +0 -0
  62. package/theme-chalk/css/rx-tooltip.css +0 -0
  63. package/es/components/RxButton/index.d.ts +0 -3
  64. package/es/components/RxButton/src/index.d.ts +0 -3
  65. package/es/components/RxButton/src/index.vue.d.ts +0 -10
  66. package/es/components/index.d.ts +0 -2
  67. package/lib/components/RxButton/index.d.ts +0 -3
  68. package/lib/components/RxButton/src/index.d.ts +0 -3
  69. package/lib/components/RxButton/src/index.vue.d.ts +0 -10
  70. package/lib/components/index.d.ts +0 -2
  71. package/types/components/RxButton/index.d.ts +0 -3
  72. package/types/components/RxButton/src/index.d.ts +0 -3
  73. package/types/components/RxButton/src/index.vue.d.ts +0 -10
  74. package/types/components/index.d.ts +0 -2
  75. package/types/utils/with-install.d.ts +0 -3
@@ -1 +1,14 @@
1
1
  export * from './RxButton';
2
+ export * from './RxOption';
3
+ export * from './RxSelect';
4
+ export * from './RxSelectPlus';
5
+ export * from './RxTooltip';
6
+ export * from './RxInput';
7
+ export * from './RxCheckbox';
8
+ export * from './RxCheckboxGroup';
9
+ export * from './RxSuperCondition';
10
+ export * from './RxRadio';
11
+ export * from './RxRadioGroup';
12
+ export * from './RxRadioButton';
13
+ export * from './RxScrollbar';
14
+ export * from './RxDatePicker';
package/es/index.d.ts CHANGED
@@ -1,5 +1,4 @@
1
1
  import type { App } from 'vue';
2
- import 'virtual:windi.css';
3
2
  declare const _default: {
4
3
  install: (app: App<any>) => void;
5
4
  };
package/es/index.js CHANGED
@@ -1,6 +1,5 @@
1
1
  import * as components from 'rx-compo/es/components';
2
2
  export * from 'rx-compo/es/components';
3
- import 'virtual:windi.css';
4
3
 
5
4
  const install = (app) => {
6
5
  Object.entries(components).forEach(([name, component]) => {
@@ -0,0 +1,10 @@
1
+ import { InjectionKey } from 'vue';
2
+ export interface CreateContextOptions {
3
+ readonly?: boolean;
4
+ createProvider?: boolean;
5
+ native?: boolean;
6
+ }
7
+ export declare function createContext<T>(context: any, key?: InjectionKey<T>, options?: CreateContextOptions): {
8
+ state: any;
9
+ };
10
+ export declare function useContext<T>(key: InjectionKey<T>, native?: boolean): T;
@@ -0,0 +1,13 @@
1
+ import { provide, inject, reactive, readonly as defineReadonly } from 'vue';
2
+ export function createContext(context, key = Symbol(), options = {}) {
3
+ const { readonly = true, createProvider = false, native = false } = options;
4
+ const state = reactive(context);
5
+ const provideData = readonly ? defineReadonly(state) : state;
6
+ !createProvider && provide(key, native ? context : provideData);
7
+ return {
8
+ state
9
+ };
10
+ }
11
+ export function useContext(key = Symbol(), defaultValue) {
12
+ return inject(key, defaultValue || {});
13
+ }
@@ -0,0 +1,4 @@
1
+ export declare function useTextOverflow(componentsName: string): {
2
+ isOverflowed: import("@vue/reactivity").Ref<boolean>;
3
+ checkOverflowCustom: (node: any) => void;
4
+ };
@@ -0,0 +1,13 @@
1
+ import { ref } from 'vue';
2
+ export function useTextOverflow(componentsName) {
3
+ const isOverflowed = ref(false);
4
+ function checkOverflowCustom(node) {
5
+ switch (componentsName) {
6
+ case 'RxSelectPlus':
7
+ const textElement = node.getElementsByClassName('el-input__inner')[0];
8
+ isOverflowed.value = textElement.scrollWidth > textElement.offsetWidth;
9
+ break;
10
+ }
11
+ }
12
+ return { isOverflowed, checkOverflowCustom };
13
+ }
@@ -1,3 +1,3 @@
1
1
  import type { Plugin } from 'vue';
2
- export declare type SFCWithInstall<T> = T & Plugin;
3
- export declare const withInstall: <T>(comp: any) => SFCWithInstall<T>;
2
+ export type SFCWithInstall<T> = T & Plugin;
3
+ export declare const withInstall: <T>(comp: any) => any;