@flux-ui/types 3.0.0-next.3 → 3.0.0-next.30

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/README.md CHANGED
@@ -1,45 +1,3 @@
1
- # Flux
1
+ # `@flux-ui/types`
2
2
 
3
- This repository contains the source code for the basic components that are used throughout our front-end projects. It
4
- targets Vue 3+. Please read the following instructions and checks in order to proceed.
5
-
6
- ## 📦 Registry
7
-
8
- - The UI library package is available under `@flux-ui/components`.
9
- - The Dashboard library package is available under `@flux-ui/dashboard`.
10
- - The internal package is available under `@flux-ui/internals`.
11
-
12
- ## ⚠️ Requirements
13
-
14
- - Install Node.js ^22
15
- - Install pnpm using `npm i -g pnpm`.
16
- - Configure a new environment variable `FONTAWESOME_NPM_AUTH_TOKEN`. This should be a valid Font Awesome private npm auth token.
17
- - Use `pnpm install` to install the required packages.
18
- - Use `pnpm dev` to start a build watcher for both targets.
19
- - Use `pnpm build` to build a production bundle.
20
- - Use `pnpm link` to link the dist folder of flux to your global node_modules.
21
-
22
- ## 🪵 Git
23
-
24
- All commit messages and branches will be in English.
25
-
26
- ### Branches
27
-
28
- - **Main** — Contains the latest stable release and is the exact source that is running in production.
29
- - **Develop** — Contains the latest staging release that is marked for deployment and is the exact source that is running on staging.
30
- - **Feature branches** — Any feature should have its own feature branch. Once complete, the branch should be merged into the _develop_ branch and the feature branch should be deleted.
31
- - **Bugfix branches** — When a bug is found, it should be fixed within a bugfix branch. Once complete the branch should be merged into the _develop_ branch and the feature branch should be deleted.
32
-
33
- ### Commit messages
34
-
35
- Commit messages are bound to the following templates:
36
-
37
- - `<type>: <message> `
38
- - `<type>(<feature>): <message>`
39
- - `<type>(<feature>): <message> [<issue-number>]`
40
-
41
- #### Examples
42
-
43
- - `feat(expandable): adds header slot to expandable.`
44
- - `feat(expandable): adds header slot to expandable. [FLUX-123]`
45
- - `chore: adds vue 3 build target.`
3
+ Contains all public types that are used in various `@flux-ui` packages.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@flux-ui/types",
3
3
  "description": "Contains all public types of Flux UI packages.",
4
- "version": "3.0.0-next.3",
4
+ "version": "3.0.0-next.30",
5
5
  "type": "module",
6
6
  "license": "MIT",
7
7
  "funding": "https://github.com/sponsors/basmilius",
@@ -9,21 +9,12 @@
9
9
  "repository": {
10
10
  "type": "git",
11
11
  "url": "git+https://github.com/basmilius/flux.git",
12
- "directory": "packages/primitives"
12
+ "directory": "packages/types"
13
13
  },
14
14
  "keywords": [
15
- "ui library",
16
- "component library",
17
- "design system",
18
- "vue",
19
- "vue 3",
20
- "ui",
21
- "components",
22
- "flux"
15
+ "flux",
16
+ "types"
23
17
  ],
24
- "scripts": {
25
- "prepublishOnly": "cp ../../README.md ."
26
- },
27
18
  "exports": {
28
19
  ".": "./src/index.ts"
29
20
  },
@@ -42,6 +33,7 @@
42
33
  "sideEffects": false,
43
34
  "dependencies": {},
44
35
  "devDependencies": {
45
- "@types/luxon": "^3.6.2"
36
+ "@fortawesome/fontawesome-common-types": "^7.2.0",
37
+ "@types/luxon": "^3.7.1"
46
38
  }
47
39
  }
package/src/common.ts CHANGED
@@ -1,9 +1,11 @@
1
- import type { FontAwesome } from './font-awesome';
2
- import type { MaterialSymbol } from './material-symbols';
1
+ import type { IconName as FontAwesome } from '@fortawesome/fontawesome-common-types';
3
2
 
4
- export type FluxIconName = FontAwesome | MaterialSymbol;
5
- export type FluxFontAwesomeIconName = FontAwesome;
6
- export type FluxMaterialIconName = MaterialSymbol;
3
+ export type FluxIconName = FontAwesome;
4
+
5
+ export type FluxAlignment =
6
+ | 'start'
7
+ | 'center'
8
+ | 'end';
7
9
 
8
10
  export type FluxColor =
9
11
  | 'gray'
package/src/filter.ts CHANGED
@@ -41,6 +41,7 @@ export type FluxFilterOptionHeader = {
41
41
  };
42
42
 
43
43
  export type FluxFilterOptionItem = {
44
+ readonly icon?: FluxIconName;
44
45
  readonly label: string;
45
46
  readonly value: FluxFilterValueSingle;
46
47
  };
@@ -60,10 +61,4 @@ export type FluxFilterValue =
60
61
  | FluxFilterValueSingle
61
62
  | FluxFilterValueSingle[];
62
63
 
63
- export type FluxFilterState = {
64
- get resettable(): string[];
65
-
66
- reset(): void;
67
- } & {
68
- [key: string]: FluxFilterValue | Function;
69
- };
64
+ export type FluxFilterState = Record<string, FluxFilterValue>;
package/src/form.ts CHANGED
@@ -10,6 +10,8 @@ export type FluxFormSelectOption = {
10
10
  readonly command?: string;
11
11
  readonly commandIcon?: FluxIconName;
12
12
  readonly icon?: FluxIconName;
13
+ readonly imageAlt?: string;
14
+ readonly imageSrc?: string;
13
15
  readonly label: string;
14
16
  readonly selectable?: boolean;
15
17
  readonly value: string | number | null;
package/src/index.ts CHANGED
@@ -1,12 +1,11 @@
1
1
  export type {
2
+ FluxAlignment,
2
3
  FluxAutoCompleteType,
3
4
  FluxColor,
4
5
  FluxDirection,
5
- FluxFontAwesomeIconName,
6
6
  FluxIconName,
7
7
  FluxInputMask,
8
8
  FluxInputType,
9
- FluxMaterialIconName,
10
9
  FluxMaybePromise,
11
10
  FluxPressableType,
12
11
  FluxSize,
@@ -56,3 +55,7 @@ export type {
56
55
  FluxSnackbarObject,
57
56
  FluxTooltipObject
58
57
  } from './notify';
58
+
59
+ export type {
60
+ FluxStatisticsChange
61
+ } from './statistics';
@@ -0,0 +1,7 @@
1
+ import type { FluxColor, FluxIconName } from './common';
2
+
3
+ export type FluxStatisticsChange = {
4
+ readonly color?: FluxColor;
5
+ readonly icon?: FluxIconName;
6
+ readonly value: string | number;
7
+ };