@naptics/vue-collection 0.2.14 → 0.3.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.
- package/.github/workflows/build.yml +26 -0
- package/.github/workflows/deploy-demo.yml +46 -0
- package/.github/workflows/deploy-lib.yml +65 -0
- package/.gitlab-ci.yml +57 -0
- package/.nvmrc +1 -0
- package/.prettierrc +8 -0
- package/.vscode/extensions.json +10 -0
- package/.vscode/launch.json +23 -0
- package/.vscode/settings.json +13 -0
- package/babel.config.json +3 -0
- package/components/NAlert.d.ts +1 -44
- package/components/NBadge.d.ts +1 -133
- package/components/NBreadcrub.d.ts +2 -106
- package/components/NBreadcrub.js +1 -1
- package/components/NButton.d.ts +2 -118
- package/components/NCheckbox.d.ts +1 -32
- package/components/NCheckboxLabel.d.ts +1 -45
- package/components/NCheckboxLabel.js +1 -1
- package/components/NCrudModal.d.ts +9 -221
- package/components/NCrudModal.js +1 -1
- package/components/NDialog.d.ts +1 -110
- package/components/NDialog.js +1 -1
- package/components/NDropdown.d.ts +1 -69
- package/components/NDropdown.js +1 -1
- package/components/NDropzone.d.ts +1 -115
- package/components/NDropzone.js +1 -1
- package/components/NForm.d.ts +1 -23
- package/components/NFormModal.d.ts +9 -127
- package/components/NIconButton.d.ts +3 -159
- package/components/NIconButton.js +1 -1
- package/components/NIconCircle.d.ts +1 -87
- package/components/NInput.d.ts +1 -164
- package/components/NInput.js +1 -1
- package/components/NInputPhone.d.ts +2 -114
- package/components/NInputPhone.js +1 -1
- package/components/NInputSelect.d.ts +2 -187
- package/components/NInputSelect.js +1 -1
- package/components/NInputSuggestion.d.ts +2 -155
- package/components/NInputSuggestion.js +1 -1
- package/components/NLink.d.ts +1 -70
- package/components/NList.d.ts +1 -43
- package/components/NList.js +1 -1
- package/components/NLoadingIndicator.d.ts +1 -49
- package/components/NModal.d.ts +15 -227
- package/components/NModal.js +16 -2
- package/components/NPagination.d.ts +1 -63
- package/components/NSearchbar.d.ts +1 -56
- package/components/NSearchbarList.d.ts +3 -63
- package/components/NSearchbarList.js +1 -1
- package/components/NSelect.d.ts +2 -148
- package/components/NSelect.js +1 -1
- package/components/NSuggestionList.d.ts +3 -126
- package/components/NSuggestionList.js +5 -2
- package/components/NTable.d.ts +1 -85
- package/components/NTable.js +12 -6
- package/components/NTableAction.d.ts +2 -46
- package/components/NTableAction.js +1 -1
- package/components/NTextArea.d.ts +2 -181
- package/components/NTextArea.js +1 -1
- package/components/NTooltip.d.ts +1 -105
- package/components/NTooltip.js +1 -1
- package/components/NValInput.d.ts +7 -182
- package/components/NValInput.js +1 -1
- package/env.d.ts +15 -0
- package/eslint.config.cjs +29 -0
- package/index.html +13 -0
- package/package.json +21 -19
- package/postcss.config.js +6 -0
- package/public/favicon.ico +0 -0
- package/scripts/build-lib.sh +52 -0
- package/scripts/sync-node-types.js +70 -0
- package/src/demo/App.css +9 -0
- package/src/demo/App.tsx +5 -0
- package/src/demo/components/ColorGrid.tsx +26 -0
- package/src/demo/components/ComponentGrid.tsx +26 -0
- package/src/demo/components/ComponentSection.tsx +30 -0
- package/src/demo/components/VariantSection.tsx +18 -0
- package/src/demo/i18n/de.ts +7 -0
- package/src/demo/i18n/en.ts +7 -0
- package/src/demo/i18n/index.ts +24 -0
- package/src/demo/main.ts +13 -0
- package/src/demo/router/index.ts +21 -0
- package/src/demo/views/HomeView.tsx +94 -0
- package/src/demo/views/NavigationView.tsx +43 -0
- package/src/demo/views/presentation/AlertView.tsx +40 -0
- package/src/demo/views/presentation/BadgeView.tsx +61 -0
- package/src/demo/views/presentation/BreadcrumbView.tsx +52 -0
- package/src/demo/views/presentation/ButtonView.tsx +49 -0
- package/src/demo/views/presentation/CheckboxView.tsx +59 -0
- package/src/demo/views/presentation/DropdownView.tsx +59 -0
- package/src/demo/views/presentation/DropzoneView.tsx +39 -0
- package/src/demo/views/presentation/IconButtonView.tsx +47 -0
- package/src/demo/views/presentation/IconCircleView.tsx +38 -0
- package/src/demo/views/presentation/InputView.tsx +179 -0
- package/src/demo/views/presentation/LinkView.tsx +50 -0
- package/src/demo/views/presentation/ListView.tsx +29 -0
- package/src/demo/views/presentation/LoadingIndicatorView.tsx +38 -0
- package/src/demo/views/presentation/ModalView.tsx +210 -0
- package/src/demo/views/presentation/PaginationView.tsx +25 -0
- package/src/demo/views/presentation/SearchbarView.tsx +80 -0
- package/src/demo/views/presentation/TableView.tsx +146 -0
- package/src/demo/views/presentation/TooltipView.tsx +86 -0
- package/src/lib/components/NAlert.tsx +85 -0
- package/src/lib/components/NBadge.tsx +75 -0
- package/src/lib/components/NBreadcrub.tsx +97 -0
- package/src/lib/components/NButton.tsx +80 -0
- package/src/lib/components/NCheckbox.tsx +55 -0
- package/src/lib/components/NCheckboxLabel.tsx +51 -0
- package/src/lib/components/NCrudModal.tsx +133 -0
- package/src/lib/components/NDialog.tsx +182 -0
- package/src/lib/components/NDropdown.tsx +167 -0
- package/src/lib/components/NDropzone.tsx +265 -0
- package/src/lib/components/NForm.tsx +32 -0
- package/src/lib/components/NFormModal.tsx +66 -0
- package/src/lib/components/NIconButton.tsx +92 -0
- package/src/lib/components/NIconCircle.tsx +78 -0
- package/src/lib/components/NInput.css +11 -0
- package/src/lib/components/NInput.tsx +139 -0
- package/src/lib/components/NInputPhone.tsx +53 -0
- package/src/lib/components/NInputSelect.tsx +126 -0
- package/src/lib/components/NInputSuggestion.tsx +80 -0
- package/src/lib/components/NLink.tsx +68 -0
- package/src/lib/components/NList.tsx +67 -0
- package/src/lib/components/NLoadingIndicator.css +46 -0
- package/src/lib/components/NLoadingIndicator.tsx +63 -0
- package/src/lib/components/NModal.tsx +243 -0
- package/src/lib/components/NPagination.css +15 -0
- package/src/lib/components/NPagination.tsx +131 -0
- package/src/lib/components/NSearchbar.tsx +78 -0
- package/src/lib/components/NSearchbarList.tsx +47 -0
- package/src/lib/components/NSelect.tsx +128 -0
- package/src/lib/components/NSuggestionList.tsx +216 -0
- package/src/lib/components/NTable.css +3 -0
- package/src/lib/components/NTable.tsx +247 -0
- package/src/lib/components/NTableAction.tsx +49 -0
- package/src/lib/components/NTextArea.tsx +159 -0
- package/src/lib/components/NTooltip.css +37 -0
- package/src/lib/components/NTooltip.tsx +250 -0
- package/src/lib/components/NValInput.tsx +163 -0
- package/src/lib/components/ValidatedForm.ts +71 -0
- package/src/lib/components/__tests__/NButton.spec.tsx +26 -0
- package/src/lib/components/__tests__/NCheckbox.spec.tsx +39 -0
- package/src/lib/i18n/de/vue-collection.json +58 -0
- package/src/lib/i18n/en/vue-collection.json +58 -0
- package/src/lib/i18n/index.ts +54 -0
- package/src/lib/index.ts +2 -0
- package/src/lib/jsx.d.ts +13 -0
- package/src/lib/utils/__tests__/identifiable.spec.ts +72 -0
- package/src/lib/utils/__tests__/validation.spec.ts +92 -0
- package/src/lib/utils/breakpoints.ts +47 -0
- package/src/lib/utils/component.tsx +131 -0
- package/src/lib/utils/deferred.ts +28 -0
- package/src/lib/utils/identifiable.ts +87 -0
- package/src/lib/utils/stringMaxLength.ts +25 -0
- package/src/lib/utils/tailwind.ts +41 -0
- package/src/lib/utils/utils.ts +90 -0
- package/src/lib/utils/vModel.ts +260 -0
- package/src/lib/utils/validation.ts +189 -0
- package/src/lib/utils/vue.ts +25 -0
- package/tailwind.config.js +38 -0
- package/tsconfig.config.json +9 -0
- package/tsconfig.demo.json +19 -0
- package/tsconfig.json +16 -0
- package/tsconfig.lib.json +18 -0
- package/tsconfig.vitest.json +8 -0
- package/utils/breakpoints.d.ts +1 -1
- package/utils/component.d.ts +3 -7
- package/utils/component.js +5 -2
- package/utils/identifiable.js +5 -1
- package/vite.config.ts +28 -0
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
name: Lint, Type-Check, Build & Test
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches:
|
|
6
|
+
- '**'
|
|
7
|
+
|
|
8
|
+
jobs:
|
|
9
|
+
build:
|
|
10
|
+
name: Lint, Type-Check, Build & Test
|
|
11
|
+
runs-on: ubuntu-latest
|
|
12
|
+
steps:
|
|
13
|
+
- name: Checkout repository
|
|
14
|
+
uses: actions/checkout@v4
|
|
15
|
+
- name: Read .nvmrc
|
|
16
|
+
run: echo "NVMRC=$(cat .nvmrc)" >> $GITHUB_OUTPUT
|
|
17
|
+
id: nvm
|
|
18
|
+
- name: Setup node environment
|
|
19
|
+
uses: actions/setup-node@v4
|
|
20
|
+
with:
|
|
21
|
+
node-version: ${{ steps.nvm.outputs.NVMRC }}
|
|
22
|
+
- run: npm ci
|
|
23
|
+
- run: npm run lint
|
|
24
|
+
- run: npm run build-lib
|
|
25
|
+
- run: npm run build-demo
|
|
26
|
+
- run: npm run test
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
name: Deploy Demo App to Github Pages
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches:
|
|
6
|
+
- main
|
|
7
|
+
|
|
8
|
+
permissions:
|
|
9
|
+
contents: read
|
|
10
|
+
pages: write
|
|
11
|
+
id-token: write
|
|
12
|
+
|
|
13
|
+
env:
|
|
14
|
+
VITE_BASE_PATH: vue-collection/
|
|
15
|
+
|
|
16
|
+
jobs:
|
|
17
|
+
build:
|
|
18
|
+
name: Lint, Type-Check, Build & Test
|
|
19
|
+
runs-on: ubuntu-latest
|
|
20
|
+
steps:
|
|
21
|
+
- name: Checkout repository
|
|
22
|
+
uses: actions/checkout@v4
|
|
23
|
+
- name: Setup Pages
|
|
24
|
+
uses: actions/configure-pages@v5
|
|
25
|
+
- name: Read .nvmrc
|
|
26
|
+
run: echo "NVMRC=$(cat .nvmrc)" >> $GITHUB_OUTPUT
|
|
27
|
+
id: nvm
|
|
28
|
+
- name: Setup node environment
|
|
29
|
+
uses: actions/setup-node@v4
|
|
30
|
+
with:
|
|
31
|
+
node-version: ${{ steps.nvm.outputs.NVMRC }}
|
|
32
|
+
- run: npm ci
|
|
33
|
+
- run: npm run lint
|
|
34
|
+
- run: npm run build-demo
|
|
35
|
+
- run: npm run test
|
|
36
|
+
- name: Upload demo as artifact
|
|
37
|
+
uses: actions/upload-pages-artifact@v3
|
|
38
|
+
with:
|
|
39
|
+
path: 'dist'
|
|
40
|
+
deploy:
|
|
41
|
+
name: Deploy Demo App To Github Pages
|
|
42
|
+
needs: build
|
|
43
|
+
runs-on: ubuntu-latest
|
|
44
|
+
steps:
|
|
45
|
+
- name: Deploy to GitHub Pages
|
|
46
|
+
uses: actions/deploy-pages@v4
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
name: Deploy Library to npm
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
tags:
|
|
6
|
+
- v*
|
|
7
|
+
|
|
8
|
+
jobs:
|
|
9
|
+
build:
|
|
10
|
+
name: Lint, Type-Check, Build & Test
|
|
11
|
+
runs-on: ubuntu-latest
|
|
12
|
+
steps:
|
|
13
|
+
- name: Checkout repository
|
|
14
|
+
uses: actions/checkout@v4
|
|
15
|
+
- name: Read .nvmrc
|
|
16
|
+
run: echo "NVMRC=$(cat .nvmrc)" >> $GITHUB_OUTPUT
|
|
17
|
+
id: nvm
|
|
18
|
+
- name: Setup node environment
|
|
19
|
+
uses: actions/setup-node@v4
|
|
20
|
+
with:
|
|
21
|
+
node-version: ${{ steps.nvm.outputs.NVMRC }}
|
|
22
|
+
- run: npm ci
|
|
23
|
+
- run: npm run lint
|
|
24
|
+
- run: npm run build-lib
|
|
25
|
+
- run: npm run test
|
|
26
|
+
- name: Upload library as artifact
|
|
27
|
+
uses: actions/upload-artifact@v4
|
|
28
|
+
with:
|
|
29
|
+
name: vue-collection-lib
|
|
30
|
+
path: |
|
|
31
|
+
lib
|
|
32
|
+
.npmrc
|
|
33
|
+
package.json
|
|
34
|
+
README.md
|
|
35
|
+
deploy:
|
|
36
|
+
name: Deploy Library to npm
|
|
37
|
+
needs: build
|
|
38
|
+
runs-on: ubuntu-latest
|
|
39
|
+
permissions:
|
|
40
|
+
id-token: write # Required for OIDC
|
|
41
|
+
contents: read
|
|
42
|
+
steps:
|
|
43
|
+
- name: Checkout repository
|
|
44
|
+
uses: actions/checkout@v4
|
|
45
|
+
- name: Read .nvmrc
|
|
46
|
+
run: echo "NVMRC=$(cat .nvmrc)" >> $GITHUB_OUTPUT
|
|
47
|
+
id: nvm
|
|
48
|
+
- name: Setup node environment
|
|
49
|
+
uses: actions/setup-node@v4
|
|
50
|
+
env:
|
|
51
|
+
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
|
|
52
|
+
with:
|
|
53
|
+
node-version: ${{ steps.nvm.outputs.NVMRC }}
|
|
54
|
+
registry-url: https://registry.npmjs.org/
|
|
55
|
+
# Ensure npm 11.5.1 or later for trusted publishing
|
|
56
|
+
- name: Ensure latest npm version
|
|
57
|
+
run: npm --version
|
|
58
|
+
- run: npm install -g npm@latest --no-man
|
|
59
|
+
- name: Download library artifact
|
|
60
|
+
uses: actions/download-artifact@v4
|
|
61
|
+
with:
|
|
62
|
+
name: vue-collection-lib
|
|
63
|
+
- name: Prepare folder structure
|
|
64
|
+
run: mv ./lib/* .
|
|
65
|
+
- run: npm publish --access=public
|
package/.gitlab-ci.yml
ADDED
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
cache:
|
|
2
|
+
paths:
|
|
3
|
+
- node_modules/
|
|
4
|
+
|
|
5
|
+
default:
|
|
6
|
+
image: node:18-alpine3.15
|
|
7
|
+
|
|
8
|
+
stages:
|
|
9
|
+
- prebuild
|
|
10
|
+
- build
|
|
11
|
+
- deploy
|
|
12
|
+
|
|
13
|
+
workflow:
|
|
14
|
+
rules:
|
|
15
|
+
- if: $CI_PIPELINE_SOURCE == "merge_request_event"
|
|
16
|
+
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
|
|
17
|
+
|
|
18
|
+
prebuild:
|
|
19
|
+
stage: prebuild
|
|
20
|
+
before_script:
|
|
21
|
+
- npm ci
|
|
22
|
+
script:
|
|
23
|
+
- npm run type-check
|
|
24
|
+
- npm run lint
|
|
25
|
+
- npm run test
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
build-pages:
|
|
29
|
+
stage: build
|
|
30
|
+
before_script:
|
|
31
|
+
- npm ci
|
|
32
|
+
script:
|
|
33
|
+
- export VITE_BASE_PATH="${CI_PROJECT_PATH#$CI_PROJECT_ROOT_NAMESPACE}/"
|
|
34
|
+
- npm run build
|
|
35
|
+
artifacts:
|
|
36
|
+
paths:
|
|
37
|
+
- dist/
|
|
38
|
+
expire_in: 1 day
|
|
39
|
+
|
|
40
|
+
pages:
|
|
41
|
+
stage: deploy
|
|
42
|
+
image: busybox:latest
|
|
43
|
+
environment:
|
|
44
|
+
name: Showroom
|
|
45
|
+
url: $CI_PAGES_URL
|
|
46
|
+
script:
|
|
47
|
+
- rm -rf public
|
|
48
|
+
- mkdir public
|
|
49
|
+
- mv dist/* public
|
|
50
|
+
artifacts:
|
|
51
|
+
paths:
|
|
52
|
+
- public
|
|
53
|
+
rules:
|
|
54
|
+
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
|
package/.nvmrc
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
24
|
package/.prettierrc
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
// Use IntelliSense to learn about possible attributes.
|
|
3
|
+
// Hover to view descriptions of existing attributes.
|
|
4
|
+
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
|
|
5
|
+
"version": "0.2.0",
|
|
6
|
+
"configurations": [
|
|
7
|
+
{
|
|
8
|
+
"type": "chrome",
|
|
9
|
+
"request": "launch",
|
|
10
|
+
"name": "Launch Chrome Canary",
|
|
11
|
+
"url": "http://localhost:5173",
|
|
12
|
+
"webRoot": "${workspaceFolder}",
|
|
13
|
+
"runtimeExecutable": "canary"
|
|
14
|
+
},
|
|
15
|
+
{
|
|
16
|
+
"type": "chrome",
|
|
17
|
+
"request": "launch",
|
|
18
|
+
"name": "Launch Chrome (stable)",
|
|
19
|
+
"url": "http://localhost:5173",
|
|
20
|
+
"webRoot": "${workspaceFolder}"
|
|
21
|
+
}
|
|
22
|
+
]
|
|
23
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
{
|
|
2
|
+
"eslint.enable": true,
|
|
3
|
+
"prettier.enable": true,
|
|
4
|
+
"editor.defaultFormatter": "esbenp.prettier-vscode",
|
|
5
|
+
"editor.formatOnSave": true,
|
|
6
|
+
"eslint.validate": ["vue", "html", "javascript", "typescript", "javascriptreact", "typescriptreact"],
|
|
7
|
+
"css.lint.unknownAtRules": "ignore",
|
|
8
|
+
"[yaml]": {
|
|
9
|
+
"editor.insertSpaces": true,
|
|
10
|
+
"editor.tabSize": 2,
|
|
11
|
+
"editor.autoIndent": "advanced"
|
|
12
|
+
}
|
|
13
|
+
}
|
package/components/NAlert.d.ts
CHANGED
|
@@ -25,48 +25,5 @@ export declare const nAlertProps: {
|
|
|
25
25
|
* The `NAlert` is a fully styled alert with multiple variants.
|
|
26
26
|
* It can be used as a normal blocking element or as part of an alert queue.
|
|
27
27
|
*/
|
|
28
|
-
declare const Component: import("vue").
|
|
29
|
-
/**
|
|
30
|
-
* The variant of the alert. This defines its color and icon.
|
|
31
|
-
*/
|
|
32
|
-
readonly variant: {
|
|
33
|
-
readonly type: PropType<AlertVariant>;
|
|
34
|
-
readonly default: "success";
|
|
35
|
-
};
|
|
36
|
-
/**
|
|
37
|
-
* The text of the alert.
|
|
38
|
-
*/
|
|
39
|
-
readonly text: StringConstructor;
|
|
40
|
-
/**
|
|
41
|
-
* If set to `true` the X-button of the alert is hidden.
|
|
42
|
-
*/
|
|
43
|
-
readonly hideX: BooleanConstructor;
|
|
44
|
-
/**
|
|
45
|
-
* This is called, when the X-button is clicked.
|
|
46
|
-
*/
|
|
47
|
-
readonly onDismiss: PropType<() => void>;
|
|
48
|
-
}, import("vue").RenderFunction, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, never[], never, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
49
|
-
/**
|
|
50
|
-
* The variant of the alert. This defines its color and icon.
|
|
51
|
-
*/
|
|
52
|
-
readonly variant: {
|
|
53
|
-
readonly type: PropType<AlertVariant>;
|
|
54
|
-
readonly default: "success";
|
|
55
|
-
};
|
|
56
|
-
/**
|
|
57
|
-
* The text of the alert.
|
|
58
|
-
*/
|
|
59
|
-
readonly text: StringConstructor;
|
|
60
|
-
/**
|
|
61
|
-
* If set to `true` the X-button of the alert is hidden.
|
|
62
|
-
*/
|
|
63
|
-
readonly hideX: BooleanConstructor;
|
|
64
|
-
/**
|
|
65
|
-
* This is called, when the X-button is clicked.
|
|
66
|
-
*/
|
|
67
|
-
readonly onDismiss: PropType<() => void>;
|
|
68
|
-
}>> & {}, {
|
|
69
|
-
readonly variant: AlertVariant;
|
|
70
|
-
readonly hideX: boolean;
|
|
71
|
-
}>;
|
|
28
|
+
declare const Component: import("vue").DefineSetupFnComponent<Record<string, any>, {}, {}, Record<string, any> & {}, import("vue").PublicProps>;
|
|
72
29
|
export { Component as NAlert, Component as default };
|
package/components/NBadge.d.ts
CHANGED
|
@@ -65,137 +65,5 @@ export declare const nBadgeProps: {
|
|
|
65
65
|
/**
|
|
66
66
|
* The `NBadge` is a styled element to wrap a text.
|
|
67
67
|
*/
|
|
68
|
-
declare const Component: import("vue").
|
|
69
|
-
readonly tooltipText: StringConstructor;
|
|
70
|
-
readonly tooltipContent: PropType<() => JSX.Element>;
|
|
71
|
-
readonly tooltipHide: BooleanConstructor;
|
|
72
|
-
readonly tooltipShow: BooleanConstructor;
|
|
73
|
-
readonly tooltipPlacement: {
|
|
74
|
-
readonly type: PropType<import("./NTooltip").TooltipPlacement>;
|
|
75
|
-
readonly default: "auto";
|
|
76
|
-
};
|
|
77
|
-
readonly tooltipMaxWidth: {
|
|
78
|
-
readonly type: PropType<import("../utils/tailwind").TWMaxWidth>;
|
|
79
|
-
readonly default: "max-w-xs";
|
|
80
|
-
};
|
|
81
|
-
readonly tooltipWrapperClass: StringConstructor;
|
|
82
|
-
readonly tooltipContentClass: StringConstructor;
|
|
83
|
-
readonly tooltipArrowClass: StringConstructor;
|
|
84
|
-
/**
|
|
85
|
-
* The text of the badge. Can alternatively be passed in the default slot.
|
|
86
|
-
*/
|
|
87
|
-
readonly text: StringConstructor;
|
|
88
|
-
/**
|
|
89
|
-
* The text size, a standard tailwind text-size class.
|
|
90
|
-
*/
|
|
91
|
-
readonly textSize: {
|
|
92
|
-
readonly type: PropType<TWTextSize>;
|
|
93
|
-
readonly default: "text-sm";
|
|
94
|
-
};
|
|
95
|
-
/**
|
|
96
|
-
* The color of the badge.
|
|
97
|
-
*/
|
|
98
|
-
readonly color: {
|
|
99
|
-
readonly type: StringConstructor;
|
|
100
|
-
readonly default: "primary";
|
|
101
|
-
};
|
|
102
|
-
/**
|
|
103
|
-
* The background shade of the badge.
|
|
104
|
-
*/
|
|
105
|
-
readonly shade: {
|
|
106
|
-
readonly type: NumberConstructor;
|
|
107
|
-
readonly default: 200;
|
|
108
|
-
};
|
|
109
|
-
/**
|
|
110
|
-
* The text shade of the badge.
|
|
111
|
-
*/
|
|
112
|
-
readonly textShade: {
|
|
113
|
-
readonly type: NumberConstructor;
|
|
114
|
-
readonly default: 900;
|
|
115
|
-
};
|
|
116
|
-
/**
|
|
117
|
-
* If set to `true` the badges text is all-caps. Default is `true`.
|
|
118
|
-
*/
|
|
119
|
-
readonly allCaps: {
|
|
120
|
-
readonly type: BooleanConstructor;
|
|
121
|
-
readonly default: true;
|
|
122
|
-
};
|
|
123
|
-
/**
|
|
124
|
-
* Adds the classes to the badge.
|
|
125
|
-
* Use this instead of `class` to style the button, because the button is wrapped inside
|
|
126
|
-
* a div for the tooltip and `class` would be applied to the wrapping div.
|
|
127
|
-
*/
|
|
128
|
-
readonly badgeClass: StringConstructor;
|
|
129
|
-
}, import("vue").RenderFunction, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, never[], never, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
130
|
-
readonly tooltipText: StringConstructor;
|
|
131
|
-
readonly tooltipContent: PropType<() => JSX.Element>;
|
|
132
|
-
readonly tooltipHide: BooleanConstructor;
|
|
133
|
-
readonly tooltipShow: BooleanConstructor;
|
|
134
|
-
readonly tooltipPlacement: {
|
|
135
|
-
readonly type: PropType<import("./NTooltip").TooltipPlacement>;
|
|
136
|
-
readonly default: "auto";
|
|
137
|
-
};
|
|
138
|
-
readonly tooltipMaxWidth: {
|
|
139
|
-
readonly type: PropType<import("../utils/tailwind").TWMaxWidth>;
|
|
140
|
-
readonly default: "max-w-xs";
|
|
141
|
-
};
|
|
142
|
-
readonly tooltipWrapperClass: StringConstructor;
|
|
143
|
-
readonly tooltipContentClass: StringConstructor;
|
|
144
|
-
readonly tooltipArrowClass: StringConstructor;
|
|
145
|
-
/**
|
|
146
|
-
* The text of the badge. Can alternatively be passed in the default slot.
|
|
147
|
-
*/
|
|
148
|
-
readonly text: StringConstructor;
|
|
149
|
-
/**
|
|
150
|
-
* The text size, a standard tailwind text-size class.
|
|
151
|
-
*/
|
|
152
|
-
readonly textSize: {
|
|
153
|
-
readonly type: PropType<TWTextSize>;
|
|
154
|
-
readonly default: "text-sm";
|
|
155
|
-
};
|
|
156
|
-
/**
|
|
157
|
-
* The color of the badge.
|
|
158
|
-
*/
|
|
159
|
-
readonly color: {
|
|
160
|
-
readonly type: StringConstructor;
|
|
161
|
-
readonly default: "primary";
|
|
162
|
-
};
|
|
163
|
-
/**
|
|
164
|
-
* The background shade of the badge.
|
|
165
|
-
*/
|
|
166
|
-
readonly shade: {
|
|
167
|
-
readonly type: NumberConstructor;
|
|
168
|
-
readonly default: 200;
|
|
169
|
-
};
|
|
170
|
-
/**
|
|
171
|
-
* The text shade of the badge.
|
|
172
|
-
*/
|
|
173
|
-
readonly textShade: {
|
|
174
|
-
readonly type: NumberConstructor;
|
|
175
|
-
readonly default: 900;
|
|
176
|
-
};
|
|
177
|
-
/**
|
|
178
|
-
* If set to `true` the badges text is all-caps. Default is `true`.
|
|
179
|
-
*/
|
|
180
|
-
readonly allCaps: {
|
|
181
|
-
readonly type: BooleanConstructor;
|
|
182
|
-
readonly default: true;
|
|
183
|
-
};
|
|
184
|
-
/**
|
|
185
|
-
* Adds the classes to the badge.
|
|
186
|
-
* Use this instead of `class` to style the button, because the button is wrapped inside
|
|
187
|
-
* a div for the tooltip and `class` would be applied to the wrapping div.
|
|
188
|
-
*/
|
|
189
|
-
readonly badgeClass: StringConstructor;
|
|
190
|
-
}>> & {}, {
|
|
191
|
-
readonly color: string;
|
|
192
|
-
readonly shade: number;
|
|
193
|
-
readonly tooltipHide: boolean;
|
|
194
|
-
readonly tooltipShow: boolean;
|
|
195
|
-
readonly tooltipPlacement: import("./NTooltip").TooltipPlacement;
|
|
196
|
-
readonly tooltipMaxWidth: import("../utils/tailwind").TWMaxWidth;
|
|
197
|
-
readonly textSize: TWTextSize;
|
|
198
|
-
readonly textShade: number;
|
|
199
|
-
readonly allCaps: boolean;
|
|
200
|
-
}>;
|
|
68
|
+
declare const Component: import("vue").DefineSetupFnComponent<Record<string, any>, {}, {}, Record<string, any> & {}, import("vue").PublicProps>;
|
|
201
69
|
export { Component as NBadge, Component as default };
|
|
@@ -29,7 +29,7 @@ export declare const nBreadcrumbProps: {
|
|
|
29
29
|
*/
|
|
30
30
|
readonly icon: {
|
|
31
31
|
readonly type: PropType<HeroIcon>;
|
|
32
|
-
readonly default: import("vue").FunctionalComponent<import("vue").HTMLAttributes & import("vue").VNodeProps, {}>;
|
|
32
|
+
readonly default: import("vue").FunctionalComponent<import("vue").HTMLAttributes & import("vue").VNodeProps, {}, any, {}>;
|
|
33
33
|
};
|
|
34
34
|
/**
|
|
35
35
|
* The size of the icon in tailwind units.
|
|
@@ -65,109 +65,5 @@ export type BreadcrumbItem = {
|
|
|
65
65
|
/**
|
|
66
66
|
* The `NBreadcrumb` is a styled breadcrumb which can be used as a navigation in hierarchical views.
|
|
67
67
|
*/
|
|
68
|
-
declare const Component: import("vue").
|
|
69
|
-
/**
|
|
70
|
-
* The items of the breadcrumb.
|
|
71
|
-
*/
|
|
72
|
-
readonly items: {
|
|
73
|
-
readonly type: PropType<BreadcrumbItem[]>;
|
|
74
|
-
readonly default: () => never[];
|
|
75
|
-
};
|
|
76
|
-
/**
|
|
77
|
-
* The color of the breadcrumbs text and icons.
|
|
78
|
-
*/
|
|
79
|
-
readonly color: {
|
|
80
|
-
readonly type: StringConstructor;
|
|
81
|
-
readonly default: "primary";
|
|
82
|
-
};
|
|
83
|
-
/**
|
|
84
|
-
* The text-size of the breadcrumb labels.
|
|
85
|
-
*/
|
|
86
|
-
readonly textSize: {
|
|
87
|
-
readonly type: PropType<TWTextSize>;
|
|
88
|
-
readonly default: "text-base";
|
|
89
|
-
};
|
|
90
|
-
/**
|
|
91
|
-
* The icon which is used as a seperator between two breadcrumb items.
|
|
92
|
-
*/
|
|
93
|
-
readonly icon: {
|
|
94
|
-
readonly type: PropType<HeroIcon>;
|
|
95
|
-
readonly default: import("vue").FunctionalComponent<import("vue").HTMLAttributes & import("vue").VNodeProps, {}>;
|
|
96
|
-
};
|
|
97
|
-
/**
|
|
98
|
-
* The size of the icon in tailwind units.
|
|
99
|
-
*/
|
|
100
|
-
readonly iconSize: {
|
|
101
|
-
readonly type: NumberConstructor;
|
|
102
|
-
readonly default: 5;
|
|
103
|
-
};
|
|
104
|
-
/**
|
|
105
|
-
* Adds the classes to the separator icons.
|
|
106
|
-
*/
|
|
107
|
-
readonly iconClass: StringConstructor;
|
|
108
|
-
/**
|
|
109
|
-
* A slot the replace the breadcrumb labels.
|
|
110
|
-
*/
|
|
111
|
-
readonly item: PropType<(item: BreadcrumbItem, index: number) => JSX.Element>;
|
|
112
|
-
/**
|
|
113
|
-
* A slot to replace the separators between the breadcrumb labels.
|
|
114
|
-
* The passsed item is the item before the seperator.
|
|
115
|
-
*/
|
|
116
|
-
readonly seperator: PropType<(item: BreadcrumbItem, index: number) => JSX.Element>;
|
|
117
|
-
}, import("vue").RenderFunction, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, never[], never, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
118
|
-
/**
|
|
119
|
-
* The items of the breadcrumb.
|
|
120
|
-
*/
|
|
121
|
-
readonly items: {
|
|
122
|
-
readonly type: PropType<BreadcrumbItem[]>;
|
|
123
|
-
readonly default: () => never[];
|
|
124
|
-
};
|
|
125
|
-
/**
|
|
126
|
-
* The color of the breadcrumbs text and icons.
|
|
127
|
-
*/
|
|
128
|
-
readonly color: {
|
|
129
|
-
readonly type: StringConstructor;
|
|
130
|
-
readonly default: "primary";
|
|
131
|
-
};
|
|
132
|
-
/**
|
|
133
|
-
* The text-size of the breadcrumb labels.
|
|
134
|
-
*/
|
|
135
|
-
readonly textSize: {
|
|
136
|
-
readonly type: PropType<TWTextSize>;
|
|
137
|
-
readonly default: "text-base";
|
|
138
|
-
};
|
|
139
|
-
/**
|
|
140
|
-
* The icon which is used as a seperator between two breadcrumb items.
|
|
141
|
-
*/
|
|
142
|
-
readonly icon: {
|
|
143
|
-
readonly type: PropType<HeroIcon>;
|
|
144
|
-
readonly default: import("vue").FunctionalComponent<import("vue").HTMLAttributes & import("vue").VNodeProps, {}>;
|
|
145
|
-
};
|
|
146
|
-
/**
|
|
147
|
-
* The size of the icon in tailwind units.
|
|
148
|
-
*/
|
|
149
|
-
readonly iconSize: {
|
|
150
|
-
readonly type: NumberConstructor;
|
|
151
|
-
readonly default: 5;
|
|
152
|
-
};
|
|
153
|
-
/**
|
|
154
|
-
* Adds the classes to the separator icons.
|
|
155
|
-
*/
|
|
156
|
-
readonly iconClass: StringConstructor;
|
|
157
|
-
/**
|
|
158
|
-
* A slot the replace the breadcrumb labels.
|
|
159
|
-
*/
|
|
160
|
-
readonly item: PropType<(item: BreadcrumbItem, index: number) => JSX.Element>;
|
|
161
|
-
/**
|
|
162
|
-
* A slot to replace the separators between the breadcrumb labels.
|
|
163
|
-
* The passsed item is the item before the seperator.
|
|
164
|
-
*/
|
|
165
|
-
readonly seperator: PropType<(item: BreadcrumbItem, index: number) => JSX.Element>;
|
|
166
|
-
}>> & {}, {
|
|
167
|
-
readonly color: string;
|
|
168
|
-
readonly icon: HeroIcon;
|
|
169
|
-
readonly textSize: TWTextSize;
|
|
170
|
-
readonly items: BreadcrumbItem[];
|
|
171
|
-
readonly iconSize: number;
|
|
172
|
-
}>;
|
|
68
|
+
declare const Component: import("vue").DefineSetupFnComponent<Record<string, any>, {}, {}, Record<string, any> & {}, import("vue").PublicProps>;
|
|
173
69
|
export { Component as NBreadcrumb, Component as default };
|
package/components/NBreadcrub.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Fragment as _Fragment, createVNode as _createVNode } from "vue";
|
|
2
2
|
import { createComponentWithSlots } from '../utils/component';
|
|
3
3
|
import { ChevronRightIcon } from '@heroicons/vue/24/solid';
|
|
4
4
|
import NLink from './NLink';
|