@buzztech/boi-ui 0.2.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/README.md +74 -0
- package/dist/api/bankStatements.d.ts +10 -0
- package/dist/api/edoc.d.ts +11 -0
- package/dist/api/files.d.ts +4 -0
- package/dist/boi-ui.css +1 -0
- package/dist/boi-ui.js +1261 -0
- package/dist/boi-ui.js.map +1 -0
- package/dist/boi-ui.umd.cjs +2 -0
- package/dist/boi-ui.umd.cjs.map +1 -0
- package/dist/components/BankSelect.vue.d.ts +20 -0
- package/dist/components/BankStatementIntegration.vue.d.ts +119 -0
- package/dist/components/BoiButton.vue.d.ts +21 -0
- package/dist/components/Button.vue.d.ts +31 -0
- package/dist/components/EmtsIntegration.vue.d.ts +33 -0
- package/dist/components/FileInput.vue.d.ts +55 -0
- package/dist/components/ui/button/Button.vue.d.ts +31 -0
- package/dist/components/ui/button/index.d.ts +6 -0
- package/dist/composables/useAccountVerification.d.ts +29 -0
- package/dist/composables/useEdocBanks.d.ts +53 -0
- package/dist/index.d.ts +21 -0
- package/dist/lib/utils.d.ts +1 -0
- package/dist/types/edoc.d.ts +73 -0
- package/package.json +61 -0
package/README.md
ADDED
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
# @buzztech/boi-ui
|
|
2
|
+
|
|
3
|
+
Vue 3 + TypeScript UI package for BOI (EDOC/EMTS bank statement components and composables).
|
|
4
|
+
|
|
5
|
+
**Full docs:** [docs/](docs/) — [README](docs/README.md), [EDOC/EMTS](docs/edoc.md), [File upload](docs/files.md)
|
|
6
|
+
|
|
7
|
+
## Installation
|
|
8
|
+
|
|
9
|
+
```bash
|
|
10
|
+
npm install @buzztech/boi-ui vue
|
|
11
|
+
# or
|
|
12
|
+
pnpm add @buzztech/boi-ui vue
|
|
13
|
+
# or
|
|
14
|
+
yarn add @buzztech/boi-ui vue
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
## Usage
|
|
18
|
+
|
|
19
|
+
```vue
|
|
20
|
+
<script setup>
|
|
21
|
+
import { BoiButton } from '@buzztech/boi-ui'
|
|
22
|
+
</script>
|
|
23
|
+
|
|
24
|
+
<template>
|
|
25
|
+
<BoiButton label="Click me" variant="primary" />
|
|
26
|
+
</template>
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
Or register globally:
|
|
30
|
+
|
|
31
|
+
```ts
|
|
32
|
+
import { createApp } from 'vue'
|
|
33
|
+
import BoiUi from '@buzztech/boi-ui'
|
|
34
|
+
import App from './App.vue'
|
|
35
|
+
|
|
36
|
+
const app = createApp(App)
|
|
37
|
+
app.use(BoiUi)
|
|
38
|
+
app.mount('#app')
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
## Development
|
|
42
|
+
|
|
43
|
+
```bash
|
|
44
|
+
pnpm install
|
|
45
|
+
pnpm build
|
|
46
|
+
pnpm type-check
|
|
47
|
+
pnpm test
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
## Releasing (`@buzztech/boi-ui`)
|
|
51
|
+
|
|
52
|
+
The published artifact is the **`dist/`** folder (see `"files"` in `package.json`). `prepublishOnly` runs `npm run build` before publish.
|
|
53
|
+
|
|
54
|
+
**Before the first publish:** the **`buzztech`** scope must exist on npm. Create a free org: [npmjs.com/org/create](https://www.npmjs.com/org/create) → organization name **`buzztech`** → add your npm user as owner. Scoped public packages still need `publishConfig.access: "public"` (already set); that does **not** replace creating the scope.
|
|
55
|
+
|
|
56
|
+
1. Bump **`version`** in `package.json` (semver).
|
|
57
|
+
2. Commit, tag, and push:
|
|
58
|
+
|
|
59
|
+
```bash
|
|
60
|
+
git tag v0.2.0
|
|
61
|
+
git push origin v0.2.0
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
3. Publish to npm:
|
|
65
|
+
|
|
66
|
+
```bash
|
|
67
|
+
npm publish
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
4. Consumers: `npm install @buzztech/boi-ui` / `pnpm add @buzztech/boi-ui` (peer: `vue@^3.4`).
|
|
71
|
+
|
|
72
|
+
### `404 Scope not found` when running `npm publish`
|
|
73
|
+
|
|
74
|
+
npm returns this when **`@buzztech` is not a valid scope** for your account (no org/user with that name on the registry). Fix: create the **`buzztech`** org on npm (link above), **or** rename the package in `package.json` to a scope you already own (e.g. `@your-npm-username/boi-ui`).
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export declare function bankStatementsUrls(applicationId: string | number, baseUrl?: string): {
|
|
2
|
+
index: string;
|
|
3
|
+
store: string;
|
|
4
|
+
update: (statementId: string | number) => string;
|
|
5
|
+
destroy: (statementId: string | number) => string;
|
|
6
|
+
uploadToEdoc: (statementId: string | number) => string;
|
|
7
|
+
};
|
|
8
|
+
export declare const bankStatementsApi: {
|
|
9
|
+
urls: typeof bankStatementsUrls;
|
|
10
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* EDOC API endpoint paths. Host app builds full URLs (e.g. baseURL + path).
|
|
3
|
+
*/
|
|
4
|
+
export declare const edocApi: {
|
|
5
|
+
readonly getBanks: () => string;
|
|
6
|
+
readonly initializeConsent: () => string;
|
|
7
|
+
readonly attachAccount: () => string;
|
|
8
|
+
readonly getTransactions: () => string;
|
|
9
|
+
readonly manualUpload: () => string;
|
|
10
|
+
};
|
|
11
|
+
export type EdocApi = typeof edocApi;
|
package/dist/boi-ui.css
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
:root{--boi-primary: #016837;--boi-secondary: #8f8f8f;--boi-success: #22c55e;--boi-success-foreground: #ffffff;--boi-danger: #ea2228;--boi-danger-foreground: #ffffff;--boi-surface: #ffffff;--boi-surface-muted: #f3f4f6;--boi-border: #e5e7eb;--boi-text: #000000;--boi-text-muted: #6b7280}.boi-button[data-v-96425342]{padding:.5rem 1rem;border-radius:.375rem;font-weight:500;cursor:pointer;border:none}.boi-button--primary[data-v-96425342]{background:#2563eb;color:#fff}.boi-button--primary[data-v-96425342]:hover{background:#1d4ed8}.boi-button--secondary[data-v-96425342]{background:#e5e7eb;color:#374151}.boi-button--secondary[data-v-96425342]:hover{background:#d1d5db}
|