@dcrackel/hematournamentui 1.0.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/.storybook/main.js +17 -0
- package/.storybook/preview-head.html +1 -0
- package/.storybook/preview.js +17 -0
- package/HemaTournamentUI/.gitattributes +2 -0
- package/HemaTournamentUI/LICENSE +21 -0
- package/README.md +83 -0
- package/dist/my-library.es.js +723 -0
- package/dist/my-library.umd.js +1 -0
- package/index.html +12 -0
- package/package.json +42 -0
- package/postcss.config.js +6 -0
- package/src/assets/default-tournament.png +0 -0
- package/src/index.js +15 -0
- package/src/main.js +2 -0
- package/src/mocks/fileMock.js +1 -0
- package/src/mocks/tournamentMock.js +34 -0
- package/src/stories/Base/Button/BaseButton.stories.js +69 -0
- package/src/stories/Base/Button/BaseButton.vue +141 -0
- package/src/stories/Base/Input/BaseInput.stories.js +28 -0
- package/src/stories/Base/Input/BaseInput.vue +44 -0
- package/src/stories/Base/Tag/BaseTag.stories.js +29 -0
- package/src/stories/Base/Tag/BaseTag.vue +57 -0
- package/src/stories/Base/Text/BaseText.stories.js +77 -0
- package/src/stories/Base/Text/BaseText.vue +162 -0
- package/src/stories/Cards/TournamentCard/Detail/TournamentCardDetail.stories.js +33 -0
- package/src/stories/Cards/TournamentCard/Detail/TournamentCardDetail.vue +38 -0
- package/src/stories/Cards/TournamentCard/Header/TournamentCardHeader.stories.js +48 -0
- package/src/stories/Cards/TournamentCard/Header/TournamentCardHeader.vue +40 -0
- package/src/stories/Cards/TournamentCard/TournamentCard.stories.js +37 -0
- package/src/stories/Cards/TournamentCard/TournamentCard.vue +35 -0
- package/src/stories/Configure.mdx +320 -0
- package/src/stories/Containers/Grid/GridContainer.stories.js +27 -0
- package/src/stories/Containers/Grid/GridContainer.vue +36 -0
- package/src/stories/Filters/FilterAndSortBar/FilterAndSortBar.stories.js +36 -0
- package/src/stories/Filters/FilterAndSortBar/FilterAndSortBar.vue +39 -0
- package/src/stories/Menu/Admin/AdminLeftMenu.stories.js +23 -0
- package/src/stories/Menu/Admin/AdminLeftMenu.vue +57 -0
- package/src/stories/Menu/DropDown/DropDownMenu.stories.js +34 -0
- package/src/stories/Menu/DropDown/DropDownMenu.vue +49 -0
- package/tailwind/output.css +1047 -0
- package/tailwind/tailwind.css +4 -0
- package/tailwind.config.js +25 -0
- package/vite.config.js +20 -0
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/** @type { import('@storybook/vue3-vite').StorybookConfig } */
|
|
2
|
+
const config = {
|
|
3
|
+
stories: ["../src/**/*.mdx", "../src/**/*.stories.@(js|jsx|mjs|ts|tsx)"],
|
|
4
|
+
addons: [
|
|
5
|
+
"@storybook/addon-links",
|
|
6
|
+
"@storybook/addon-essentials",
|
|
7
|
+
"@storybook/addon-interactions",
|
|
8
|
+
],
|
|
9
|
+
framework: {
|
|
10
|
+
name: "@storybook/vue3-vite",
|
|
11
|
+
options: {},
|
|
12
|
+
},
|
|
13
|
+
docs: {
|
|
14
|
+
autodocs: "tag",
|
|
15
|
+
},
|
|
16
|
+
};
|
|
17
|
+
export default config;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<link href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0-beta3/css/all.min.css" rel="stylesheet">
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/** @type { import('@storybook/vue3').Preview } */
|
|
2
|
+
import '../tailwind/output.css';
|
|
3
|
+
import 'font-awesome/css/font-awesome.min.css';
|
|
4
|
+
|
|
5
|
+
const preview = {
|
|
6
|
+
parameters: {
|
|
7
|
+
actions: { argTypesRegex: "^on[A-Z].*" },
|
|
8
|
+
controls: {
|
|
9
|
+
matchers: {
|
|
10
|
+
color: /(background|color)$/i,
|
|
11
|
+
date: /Date$/,
|
|
12
|
+
},
|
|
13
|
+
},
|
|
14
|
+
},
|
|
15
|
+
};
|
|
16
|
+
|
|
17
|
+
export default preview;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2023 Dwain Crackel
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
# Vue 3 + Vite
|
|
2
|
+
|
|
3
|
+
This template should help get you started developing with Vue 3 in Vite. The template uses Vue 3 `<script setup>` SFCs, check out the [script setup docs](https://v3.vuejs.org/api/sfc-script-setup.html#sfc-script-setup) to learn more.
|
|
4
|
+
|
|
5
|
+
## Recommended IDE Setup
|
|
6
|
+
|
|
7
|
+
- [VS Code](https://code.visualstudio.com/) + [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) (and disable Vetur) + [TypeScript Vue Plugin (Volar)](https://marketplace.visualstudio.com/items?itemName=Vue.vscode-typescript-vue-plugin).
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
## Publishing a Storybook Library to NPM
|
|
14
|
+
Follow this guide to publish your Storybook library to NPM, making it available for others to easily npm install.
|
|
15
|
+
|
|
16
|
+
# 1. Setup & Prerequisites
|
|
17
|
+
Ensure you have an account on npm. If not, you can create one for free.
|
|
18
|
+
Verify node and npm installations:
|
|
19
|
+
```
|
|
20
|
+
Copy code
|
|
21
|
+
node -v
|
|
22
|
+
npm -v
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
# 2. Preparing Your Storybook Library
|
|
26
|
+
a. Building the Library
|
|
27
|
+
Compile your library with Vite or your bundler:
|
|
28
|
+
|
|
29
|
+
```
|
|
30
|
+
vite build
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
b. Update package.json
|
|
34
|
+
Ensure the following fields are set:
|
|
35
|
+
|
|
36
|
+
name: Name of your package.
|
|
37
|
+
version: Version number.
|
|
38
|
+
main: Main entry file (e.g., dist/index.js).
|
|
39
|
+
files: Files to include, e.g., ["dist"].
|
|
40
|
+
|
|
41
|
+
# 3. Logging in to NPM
|
|
42
|
+
Login to npm (if you haven't already):
|
|
43
|
+
|
|
44
|
+
```
|
|
45
|
+
npm login
|
|
46
|
+
```
|
|
47
|
+
Provide your username, password, and email.
|
|
48
|
+
|
|
49
|
+
# 4. Publishing to NPM
|
|
50
|
+
a. Default (Private Package)
|
|
51
|
+
For scoped private packages (@username/project-name):
|
|
52
|
+
|
|
53
|
+
```
|
|
54
|
+
npm publish
|
|
55
|
+
```
|
|
56
|
+
b. Public Package
|
|
57
|
+
For public packages:
|
|
58
|
+
|
|
59
|
+
```
|
|
60
|
+
npm publish --access=public
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
# 5. Verifying Your Package
|
|
64
|
+
Check on the npm website to verify your package's publication.
|
|
65
|
+
|
|
66
|
+
Check the registry name
|
|
67
|
+
```
|
|
68
|
+
npm get registry
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
# 6. Installing and Using the Library
|
|
72
|
+
To install the library:
|
|
73
|
+
|
|
74
|
+
```
|
|
75
|
+
npm install your-library-name
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
Users can then import and utilize your library's components.
|
|
79
|
+
|
|
80
|
+
Notes:
|
|
81
|
+
|
|
82
|
+
Always update the version in package.json before republishing.
|
|
83
|
+
Ensure only necessary files are bundled to prevent package bloat.
|