@base-framework/ui 0.0.5 → 0.0.6
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/dist/index.es.js +3 -3
- package/dist/mobile-nav-wrapper-BS9uUekR.js +505 -0
- package/dist/organisms.es.js +2 -2
- package/dist/pages.es.js +1 -1
- package/dist/sidebar-menu-page-DN5qYk-Y.js +208 -0
- package/dist/{tab-C_dZb2qH.js → tab-DE7bmr2y.js} +263 -328
- package/dist/types/components/organisms/panel.d.ts +3 -1
- package/dist/types/components/organisms/tabs/tab-group.d.ts +2 -2
- package/dist/types/components/organisms/tabs/tab-navigation.d.ts +2 -2
- package/dist/types/components/pages/page.d.ts +2 -0
- package/package.json +1 -1
- package/dist/mobile-nav-wrapper-7Qul1-mt.js +0 -578
- package/dist/sidebar-menu-page-M8hr9onX.js +0 -224
|
@@ -0,0 +1,208 @@
|
|
|
1
|
+
import { Div as t, Header as c, H1 as d, P as o } from "@base-framework/atoms";
|
|
2
|
+
import { F as l, A as x } from "./aside-template-D0KANPjh.js";
|
|
3
|
+
import { Component as h, Atom as i } from "@base-framework/base";
|
|
4
|
+
import { c as u, e as p } from "./mobile-nav-wrapper-BS9uUekR.js";
|
|
5
|
+
class n extends h {
|
|
6
|
+
/**
|
|
7
|
+
* This will declare the props for the compiler.
|
|
8
|
+
*
|
|
9
|
+
* @returns {void}
|
|
10
|
+
*/
|
|
11
|
+
declareProps() {
|
|
12
|
+
this.class = "";
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
class a extends n {
|
|
16
|
+
/**
|
|
17
|
+
* This will be called every time the route
|
|
18
|
+
* is activated.
|
|
19
|
+
*
|
|
20
|
+
* @param {object} params
|
|
21
|
+
*/
|
|
22
|
+
update(s) {
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
class S extends a {
|
|
26
|
+
/**
|
|
27
|
+
* This will render the page.
|
|
28
|
+
*
|
|
29
|
+
* @returns {object}
|
|
30
|
+
*/
|
|
31
|
+
render() {
|
|
32
|
+
return l([
|
|
33
|
+
t({ class: "flex flex-auto flex-col pt-[80px] sm:pt-0" }, this.children)
|
|
34
|
+
]);
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
class k extends a {
|
|
38
|
+
/**
|
|
39
|
+
* This will render the page.
|
|
40
|
+
*
|
|
41
|
+
* @returns {object}
|
|
42
|
+
*/
|
|
43
|
+
render() {
|
|
44
|
+
return l([
|
|
45
|
+
t({ class: "contained px-4 flex flex-auto flex-col" }, this.children)
|
|
46
|
+
]);
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
const r = i((e, s) => (e.class = "basic-page pt-[80px] sm:pt-0 flex flex-auto flex-col " + (e.class || ""), {
|
|
50
|
+
tag: "section",
|
|
51
|
+
...e,
|
|
52
|
+
children: s
|
|
53
|
+
}));
|
|
54
|
+
class w extends a {
|
|
55
|
+
/**
|
|
56
|
+
* This will render the page.
|
|
57
|
+
*
|
|
58
|
+
* @returns {object}
|
|
59
|
+
*/
|
|
60
|
+
render() {
|
|
61
|
+
return r([
|
|
62
|
+
l([
|
|
63
|
+
t({ class: "contained px-4 flex flex-auto flex-col" }, this.children)
|
|
64
|
+
])
|
|
65
|
+
]);
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
const f = i(({ title: e, description: s }) => c({ class: "sm:py-8 px-6 md:px-5 flex flex-col" }, [
|
|
69
|
+
d({ class: "scroll-m-20 text-3xl font-bold tracking-tight" }, e),
|
|
70
|
+
s && o({ class: "text-base text-muted-foreground py-2 max-w-[700px]" }, s)
|
|
71
|
+
]));
|
|
72
|
+
class F extends a {
|
|
73
|
+
/**
|
|
74
|
+
* This will declare the props for the compiler.
|
|
75
|
+
*
|
|
76
|
+
* @returns {void}
|
|
77
|
+
*/
|
|
78
|
+
declareProps() {
|
|
79
|
+
super.declareProps(), this.title = "", this.description = "";
|
|
80
|
+
}
|
|
81
|
+
/**
|
|
82
|
+
* This will render the page.
|
|
83
|
+
*
|
|
84
|
+
* @returns {object}
|
|
85
|
+
*/
|
|
86
|
+
render() {
|
|
87
|
+
return r([
|
|
88
|
+
f({
|
|
89
|
+
title: this.title,
|
|
90
|
+
description: this.description
|
|
91
|
+
}),
|
|
92
|
+
l(this.children)
|
|
93
|
+
]);
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
class B extends n {
|
|
97
|
+
/**
|
|
98
|
+
* This will render the page.
|
|
99
|
+
*
|
|
100
|
+
* @returns {object}
|
|
101
|
+
*/
|
|
102
|
+
render() {
|
|
103
|
+
const s = this.class ?? "";
|
|
104
|
+
return t({ class: `flex flex-col flex-auto ${s}` }, this.children);
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
class M extends a {
|
|
108
|
+
/**
|
|
109
|
+
* This will declare the props for the compiler.
|
|
110
|
+
*
|
|
111
|
+
* @returns {void}
|
|
112
|
+
*/
|
|
113
|
+
declareProps() {
|
|
114
|
+
super.declareProps(), this.routes = [], this.switch = [], this.links = [], this.title = "";
|
|
115
|
+
}
|
|
116
|
+
/**
|
|
117
|
+
* This will render the page.
|
|
118
|
+
*
|
|
119
|
+
* @returns {object}
|
|
120
|
+
*/
|
|
121
|
+
render() {
|
|
122
|
+
return r(
|
|
123
|
+
{
|
|
124
|
+
route: this.addRoutes()
|
|
125
|
+
},
|
|
126
|
+
[
|
|
127
|
+
x({
|
|
128
|
+
left: this.addSidebar(),
|
|
129
|
+
right: this.addBody()
|
|
130
|
+
})
|
|
131
|
+
]
|
|
132
|
+
);
|
|
133
|
+
}
|
|
134
|
+
/**
|
|
135
|
+
* This will add the routes.
|
|
136
|
+
*
|
|
137
|
+
* @returns {array}
|
|
138
|
+
*/
|
|
139
|
+
addRoutes() {
|
|
140
|
+
return this.routes || [];
|
|
141
|
+
}
|
|
142
|
+
/**
|
|
143
|
+
* This will add the sidebar of the page.
|
|
144
|
+
*
|
|
145
|
+
* @returns {object}
|
|
146
|
+
*/
|
|
147
|
+
addSidebar() {
|
|
148
|
+
return t({ class: "flex flex-auto flex-col" }, this.addNavigation());
|
|
149
|
+
}
|
|
150
|
+
/**
|
|
151
|
+
* This will add the body of the page.
|
|
152
|
+
*
|
|
153
|
+
* @returns {object}
|
|
154
|
+
*/
|
|
155
|
+
addBody() {
|
|
156
|
+
return t({ class: "flex flex-auto flex-col" }, [
|
|
157
|
+
{
|
|
158
|
+
class: "contained",
|
|
159
|
+
switch: this.addSwitch()
|
|
160
|
+
}
|
|
161
|
+
]);
|
|
162
|
+
}
|
|
163
|
+
/**
|
|
164
|
+
* This will add the switch of the page.
|
|
165
|
+
*
|
|
166
|
+
* @returns {array}
|
|
167
|
+
*/
|
|
168
|
+
addSwitch() {
|
|
169
|
+
return this.switch || [];
|
|
170
|
+
}
|
|
171
|
+
/**
|
|
172
|
+
* This will add the navigation of the page.
|
|
173
|
+
*
|
|
174
|
+
* @returns {object}
|
|
175
|
+
*/
|
|
176
|
+
addNavigation() {
|
|
177
|
+
const s = this.getLinks();
|
|
178
|
+
return [
|
|
179
|
+
u(
|
|
180
|
+
{
|
|
181
|
+
title: this.title,
|
|
182
|
+
options: s,
|
|
183
|
+
class: "hidden lg:block"
|
|
184
|
+
}
|
|
185
|
+
),
|
|
186
|
+
p({ title: this.title, options: s })
|
|
187
|
+
];
|
|
188
|
+
}
|
|
189
|
+
/**
|
|
190
|
+
* This will get the links.
|
|
191
|
+
*
|
|
192
|
+
* @returns {array}
|
|
193
|
+
*/
|
|
194
|
+
getLinks() {
|
|
195
|
+
return this.links || [];
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
export {
|
|
199
|
+
a as B,
|
|
200
|
+
k as C,
|
|
201
|
+
w as F,
|
|
202
|
+
r as M,
|
|
203
|
+
n as P,
|
|
204
|
+
M as S,
|
|
205
|
+
S as a,
|
|
206
|
+
F as b,
|
|
207
|
+
B as c
|
|
208
|
+
};
|