@falcon-ui/falcon-ui 1.0.0 → 1.1.0

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 (51) hide show
  1. package/README.md +1 -0
  2. package/THIRD_PARTY_NOTICES.md +51 -0
  3. package/cjs/components/index.cjs +1131 -4
  4. package/cjs/components/index.cjs.map +1 -1
  5. package/cjs/components/loading/index.cjs +1186 -0
  6. package/cjs/components/loading/index.cjs.map +1 -0
  7. package/cjs/components/loading/src/loading.cjs +72 -0
  8. package/cjs/components/loading/src/loading.cjs.map +1 -0
  9. package/cjs/index.cjs +1132 -4
  10. package/cjs/index.cjs.map +1 -1
  11. package/esm/components/index.mjs +1130 -6
  12. package/esm/components/index.mjs.map +1 -1
  13. package/esm/components/loading/index.mjs +1179 -0
  14. package/esm/components/loading/index.mjs.map +1 -0
  15. package/esm/components/loading/src/loading.mjs +66 -0
  16. package/esm/components/loading/src/loading.mjs.map +1 -0
  17. package/esm/index.mjs +1131 -6
  18. package/esm/index.mjs.map +1 -1
  19. package/global.d.ts +2 -0
  20. package/package.json +7 -1
  21. package/theme/index.css +1 -1
  22. package/theme/index.scss +1 -0
  23. package/theme/src/loading.scss +52 -0
  24. package/types/components/barcode/index.d.ts +1 -1
  25. package/types/components/barcode/src/barcode.vue.d.ts +1 -1
  26. package/types/components/index.d.ts +2 -0
  27. package/types/components/input/index.d.ts +1 -1
  28. package/types/components/input/src/input.vue.d.ts +1 -1
  29. package/types/components/input-number/index.d.ts +3 -3
  30. package/types/components/input-number/src/input-number.vue.d.ts +1 -1
  31. package/types/components/loading/index.d.ts +183 -0
  32. package/types/components/loading/src/FlLoading.vue.d.ts +109 -0
  33. package/types/components/loading/src/animations/composing.d.ts +2 -0
  34. package/types/components/loading/src/animations/earth.d.ts +12 -0
  35. package/types/components/loading/src/animations/listening.d.ts +2 -0
  36. package/types/components/loading/src/animations/searching.d.ts +2 -0
  37. package/types/components/loading/src/animations/shaping.d.ts +2 -0
  38. package/types/components/loading/src/animations/solving.d.ts +2 -0
  39. package/types/components/loading/src/animations/working.d.ts +2 -0
  40. package/types/components/loading/src/earth-points.d.ts +22 -0
  41. package/types/components/loading/src/loading-frame.d.ts +4 -0
  42. package/types/components/loading/src/loading-geometry.d.ts +66 -0
  43. package/types/components/loading/src/loading-presets.d.ts +6 -0
  44. package/types/components/loading/src/loading-profiles.d.ts +7 -0
  45. package/types/components/loading/src/loading-renderer.d.ts +4 -0
  46. package/types/components/loading/src/loading.d.ts +65 -0
  47. package/types/components/loading/src/use-fl-loading.d.ts +15 -0
  48. package/types/components/loading/src/use-loading-animation.d.ts +13 -0
  49. package/types/components/loading/src/use-loading-color.d.ts +6 -0
  50. package/umd/falcon-ui.umd.js +1137 -7
  51. package/umd/falcon-ui.umd.js.map +1 -1
@@ -0,0 +1,65 @@
1
+ import type { ExtractPublicPropTypes, PropType } from 'vue';
2
+ export declare const flLoadingAnimations: readonly ["working", "searching", "solving", "listening", "composing", "shaping", "earth"];
3
+ export declare const flLoadingSizes: readonly [20, 32, 48, 64, 96];
4
+ export type FlLoadingAnimation = (typeof flLoadingAnimations)[number];
5
+ export type FlLoadingSize = (typeof flLoadingSizes)[number];
6
+ export type FlLoadingTheme = 'auto' | 'light' | 'dark';
7
+ export type FlLoadingLayout = 'inline' | 'vertical';
8
+ export declare const flLoadingProps: {
9
+ /** Whether to show the indicator. Inactive indicators retain their layout space. */
10
+ readonly active: {
11
+ readonly type: BooleanConstructor;
12
+ readonly default: true;
13
+ };
14
+ /** Dot animation, including the land-textured Earth. */
15
+ readonly animation: {
16
+ readonly type: PropType<FlLoadingAnimation>;
17
+ readonly default: "searching";
18
+ readonly validator: (v: FlLoadingAnimation) => boolean;
19
+ };
20
+ /** Canvas CSS size in pixels. Each size has its own dot density. */
21
+ readonly size: {
22
+ readonly type: PropType<FlLoadingSize>;
23
+ readonly default: 64;
24
+ readonly validator: (v: FlLoadingSize) => boolean;
25
+ };
26
+ /** Dot color; accepts CSS colors and CSS variables. */
27
+ readonly color: {
28
+ readonly type: StringConstructor;
29
+ readonly default: "";
30
+ };
31
+ /** Background theme used to choose contrasting dots. */
32
+ readonly theme: {
33
+ readonly type: PropType<FlLoadingTheme>;
34
+ readonly default: "auto";
35
+ };
36
+ /** Animation speed multiplier, clamped to 0.25–3. */
37
+ readonly speed: {
38
+ readonly type: NumberConstructor;
39
+ readonly default: 1;
40
+ };
41
+ /** Freeze the current animation time. */
42
+ readonly paused: {
43
+ readonly type: BooleanConstructor;
44
+ readonly default: false;
45
+ };
46
+ /** Accessible, selectable status text. */
47
+ readonly text: {
48
+ readonly type: StringConstructor;
49
+ readonly default: "";
50
+ };
51
+ /** Position the text beside or below the canvas. */
52
+ readonly layout: {
53
+ readonly type: PropType<FlLoadingLayout>;
54
+ readonly default: "inline";
55
+ };
56
+ /** Accessible label when no visible text is provided. */
57
+ readonly ariaLabel: {
58
+ readonly type: StringConstructor;
59
+ readonly default: "加载中";
60
+ };
61
+ };
62
+ export type FlLoadingProps = ExtractPublicPropTypes<typeof flLoadingProps>;
63
+ export declare const normalizeAnimation: (v: FlLoadingAnimation) => FlLoadingAnimation;
64
+ export declare const normalizeSize: (v: FlLoadingSize) => FlLoadingSize;
65
+ export declare const normalizeSpeed: (v: number) => number;
@@ -0,0 +1,15 @@
1
+ import type { ComputedRef, MaybeRefOrGetter, VNode } from 'vue';
2
+ import type { FlLoadingProps } from './loading';
3
+ export interface FlLoadingOptions extends Omit<FlLoadingProps, 'active'> {
4
+ background?: string;
5
+ customClass?: string;
6
+ themeTarget?: MaybeRefOrGetter<HTMLElement | null | undefined>;
7
+ }
8
+ /** Plain values are also accepted by the native directive's narrower binding type. */
9
+ export interface FlLoadingDirectiveOptions {
10
+ text: VNode;
11
+ customClass: string;
12
+ background?: string;
13
+ }
14
+ /** Create options for the ORIGINAL Element Plus directive; install vLoading separately. */
15
+ export declare function useFlLoading(active: MaybeRefOrGetter<boolean>, options?: MaybeRefOrGetter<FlLoadingOptions>): ComputedRef<false | FlLoadingDirectiveOptions>;
@@ -0,0 +1,13 @@
1
+ import type { Ref } from 'vue';
2
+ import type { FlLoadingAnimation, FlLoadingSize } from './loading';
3
+ interface AnimationOptions {
4
+ active: boolean;
5
+ paused: boolean;
6
+ animation: FlLoadingAnimation;
7
+ size: FlLoadingSize;
8
+ speed: number;
9
+ }
10
+ export declare function useLoadingAnimation(canvas: Ref<HTMLCanvasElement | undefined>, options: () => AnimationOptions, color: Ref<string>): {
11
+ available: Ref<boolean, boolean>;
12
+ };
13
+ export {};
@@ -0,0 +1,6 @@
1
+ import type { FlLoadingTheme } from './loading';
2
+ /** Resolve variables at the source element before a loading mask moves into body. */
3
+ export declare function useLoadingColor(host: () => HTMLElement | undefined | null, options: () => {
4
+ color?: string;
5
+ theme?: FlLoadingTheme;
6
+ }): import("vue").Ref<string, string>;