@molecule/app-auth-brand-header-solid 0.0.0-stage → 1.1.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/LICENSE +202 -0
- package/README.md +218 -2
- package/dist/AuthBrandHeader.d.ts +45 -0
- package/dist/AuthBrandHeader.d.ts.map +1 -0
- package/dist/AuthBrandHeader.jsx +85 -0
- package/dist/AuthBrandHeader.jsx.map +1 -0
- package/dist/index.d.ts +46 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +46 -0
- package/dist/index.js.map +1 -0
- package/dist/types.d.ts +74 -0
- package/dist/types.d.ts.map +1 -0
- package/dist/types.js +10 -0
- package/dist/types.js.map +1 -0
- package/package.json +64 -4
package/LICENSE
ADDED
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
|
|
2
|
+
Apache License
|
|
3
|
+
Version 2.0, January 2004
|
|
4
|
+
http://www.apache.org/licenses/
|
|
5
|
+
|
|
6
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
7
|
+
|
|
8
|
+
1. Definitions.
|
|
9
|
+
|
|
10
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
|
11
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
|
12
|
+
|
|
13
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
|
14
|
+
the copyright owner that is granting the License.
|
|
15
|
+
|
|
16
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
|
17
|
+
other entities that control, are controlled by, or are under common
|
|
18
|
+
control with that entity. For the purposes of this definition,
|
|
19
|
+
"control" means (i) the power, direct or indirect, to cause the
|
|
20
|
+
direction or management of such entity, whether by contract or
|
|
21
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
22
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
23
|
+
|
|
24
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
|
25
|
+
exercising permissions granted by this License.
|
|
26
|
+
|
|
27
|
+
"Source" form shall mean the preferred form for making modifications,
|
|
28
|
+
including but not limited to software source code, documentation
|
|
29
|
+
source, and configuration files.
|
|
30
|
+
|
|
31
|
+
"Object" form shall mean any form resulting from mechanical
|
|
32
|
+
transformation or translation of a Source form, including but
|
|
33
|
+
not limited to compiled object code, generated documentation,
|
|
34
|
+
and conversions to other media types.
|
|
35
|
+
|
|
36
|
+
"Work" shall mean the work of authorship, whether in Source or
|
|
37
|
+
Object form, made available under the License, as indicated by a
|
|
38
|
+
copyright notice that is included in or attached to the work
|
|
39
|
+
(an example is provided in the Appendix below).
|
|
40
|
+
|
|
41
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
|
42
|
+
form, that is based on (or derived from) the Work and for which the
|
|
43
|
+
editorial revisions, annotations, elaborations, or other modifications
|
|
44
|
+
represent, as a whole, an original work of authorship. For the purposes
|
|
45
|
+
of this License, Derivative Works shall not include works that remain
|
|
46
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
|
47
|
+
the Work and Derivative Works thereof.
|
|
48
|
+
|
|
49
|
+
"Contribution" shall mean any work of authorship, including
|
|
50
|
+
the original version of the Work and any modifications or additions
|
|
51
|
+
to that Work or Derivative Works thereof, that is intentionally
|
|
52
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
53
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
|
54
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
|
55
|
+
means any form of electronic, verbal, or written communication sent
|
|
56
|
+
to the Licensor or its representatives, including but not limited to
|
|
57
|
+
communication on electronic mailing lists, source code control systems,
|
|
58
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
|
59
|
+
Licensor for the purpose of discussing and improving the Work, but
|
|
60
|
+
excluding communication that is conspicuously marked or otherwise
|
|
61
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
|
62
|
+
|
|
63
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
64
|
+
on behalf of whom a Contribution has been received by Licensor and
|
|
65
|
+
subsequently incorporated within the Work.
|
|
66
|
+
|
|
67
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
68
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
69
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
70
|
+
copyright license to reproduce, prepare Derivative Works of,
|
|
71
|
+
publicly display, publicly perform, sublicense, and distribute the
|
|
72
|
+
Work and such Derivative Works in Source or Object form.
|
|
73
|
+
|
|
74
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
|
75
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
76
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
77
|
+
(except as stated in this section) patent license to make, have made,
|
|
78
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
79
|
+
where such license applies only to those patent claims licensable
|
|
80
|
+
by such Contributor that are necessarily infringed by their
|
|
81
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
|
82
|
+
with the Work to which such Contribution(s) was submitted. If You
|
|
83
|
+
institute patent litigation against any entity (including a
|
|
84
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
85
|
+
or a Contribution incorporated within the Work constitutes direct
|
|
86
|
+
or contributory patent infringement, then any patent licenses
|
|
87
|
+
granted to You under this License for that Work shall terminate
|
|
88
|
+
as of the date such litigation is filed.
|
|
89
|
+
|
|
90
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
|
91
|
+
Work or Derivative Works thereof in any medium, with or without
|
|
92
|
+
modifications, and in Source or Object form, provided that You
|
|
93
|
+
meet the following conditions:
|
|
94
|
+
|
|
95
|
+
(a) You must give any other recipients of the Work or
|
|
96
|
+
Derivative Works a copy of this License; and
|
|
97
|
+
|
|
98
|
+
(b) You must cause any modified files to carry prominent notices
|
|
99
|
+
stating that You changed the files; and
|
|
100
|
+
|
|
101
|
+
(c) You must retain, in the Source form of any Derivative Works
|
|
102
|
+
that You distribute, all copyright, patent, trademark, and
|
|
103
|
+
attribution notices from the Source form of the Work,
|
|
104
|
+
excluding those notices that do not pertain to any part of
|
|
105
|
+
the Derivative Works; and
|
|
106
|
+
|
|
107
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
|
108
|
+
distribution, then any Derivative Works that You distribute must
|
|
109
|
+
include a readable copy of the attribution notices contained
|
|
110
|
+
within such NOTICE file, excluding those notices that do not
|
|
111
|
+
pertain to any part of the Derivative Works, in at least one
|
|
112
|
+
of the following places: within a NOTICE text file distributed
|
|
113
|
+
as part of the Derivative Works; within the Source form or
|
|
114
|
+
documentation, if provided along with the Derivative Works; or,
|
|
115
|
+
within a display generated by the Derivative Works, if and
|
|
116
|
+
wherever such third-party notices normally appear. The contents
|
|
117
|
+
of the NOTICE file are for informational purposes only and
|
|
118
|
+
do not modify the License. You may add Your own attribution
|
|
119
|
+
notices within Derivative Works that You distribute, alongside
|
|
120
|
+
or as an addendum to the NOTICE text from the Work, provided
|
|
121
|
+
that such additional attribution notices cannot be construed
|
|
122
|
+
as modifying the License.
|
|
123
|
+
|
|
124
|
+
You may add Your own copyright statement to Your modifications and
|
|
125
|
+
may provide additional or different license terms and conditions
|
|
126
|
+
for use, reproduction, or distribution of Your modifications, or
|
|
127
|
+
for any such Derivative Works as a whole, provided Your use,
|
|
128
|
+
reproduction, and distribution of the Work otherwise complies with
|
|
129
|
+
the conditions stated in this License.
|
|
130
|
+
|
|
131
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
132
|
+
any Contribution intentionally submitted for inclusion in the Work
|
|
133
|
+
by You to the Licensor shall be under the terms and conditions of
|
|
134
|
+
this License, without any additional terms or conditions.
|
|
135
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
|
136
|
+
the terms of any separate license agreement you may have executed
|
|
137
|
+
with Licensor regarding such Contributions.
|
|
138
|
+
|
|
139
|
+
6. Trademarks. This License does not grant permission to use the trade
|
|
140
|
+
names, trademarks, service marks, or product names of the Licensor,
|
|
141
|
+
except as required for reasonable and customary use in describing the
|
|
142
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
|
143
|
+
|
|
144
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
145
|
+
agreed to in writing, Licensor provides the Work (and each
|
|
146
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
147
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
148
|
+
implied, including, without limitation, any warranties or conditions
|
|
149
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
150
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
151
|
+
appropriateness of using or redistributing the Work and assume any
|
|
152
|
+
risks associated with Your exercise of permissions under this License.
|
|
153
|
+
|
|
154
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
|
155
|
+
whether in tort (including negligence), contract, or otherwise,
|
|
156
|
+
unless required by applicable law (such as deliberate and grossly
|
|
157
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
|
158
|
+
liable to You for damages, including any direct, indirect, special,
|
|
159
|
+
incidental, or consequential damages of any character arising as a
|
|
160
|
+
result of this License or out of the use or inability to use the
|
|
161
|
+
Work (including but not limited to damages for loss of goodwill,
|
|
162
|
+
work stoppage, computer failure or malfunction, or any and all
|
|
163
|
+
other commercial damages or losses), even if such Contributor
|
|
164
|
+
has been advised of the possibility of such damages.
|
|
165
|
+
|
|
166
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
|
167
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
|
168
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
169
|
+
or other liability obligations and/or rights consistent with this
|
|
170
|
+
License. However, in accepting such obligations, You may act only
|
|
171
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
|
172
|
+
of any other Contributor, and only if You agree to indemnify,
|
|
173
|
+
defend, and hold each Contributor harmless for any liability
|
|
174
|
+
incurred by, or claims asserted against, such Contributor by reason
|
|
175
|
+
of your accepting any such warranty or additional liability.
|
|
176
|
+
|
|
177
|
+
END OF TERMS AND CONDITIONS
|
|
178
|
+
|
|
179
|
+
APPENDIX: How to apply the Apache License to your work.
|
|
180
|
+
|
|
181
|
+
To apply the Apache License to your work, attach the following
|
|
182
|
+
boilerplate notice, with the fields enclosed by brackets "[]"
|
|
183
|
+
replaced with your own identifying information. (Don't include
|
|
184
|
+
the brackets!) The text should be enclosed in the appropriate
|
|
185
|
+
comment syntax for the file format. We also recommend that a
|
|
186
|
+
file or class name and description of purpose be included on the
|
|
187
|
+
same "printed page" as the copyright notice for easier
|
|
188
|
+
identification within third-party archives.
|
|
189
|
+
|
|
190
|
+
Copyright [yyyy] [name of copyright owner]
|
|
191
|
+
|
|
192
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
193
|
+
you may not use this file except in compliance with the License.
|
|
194
|
+
You may obtain a copy of the License at
|
|
195
|
+
|
|
196
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
197
|
+
|
|
198
|
+
Unless required by applicable law or agreed to in writing, software
|
|
199
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
200
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
201
|
+
See the License for the specific language governing permissions and
|
|
202
|
+
limitations under the License.
|
package/README.md
CHANGED
|
@@ -1,3 +1,219 @@
|
|
|
1
|
-
|
|
1
|
+
<!--
|
|
2
|
+
AUTO-GENERATED — DO NOT EDIT THIS FILE.
|
|
3
|
+
Generated by `mlcl sync-docs` from the package's src/index.ts JSDoc + mlcl/registry.json.
|
|
4
|
+
Edits here are overwritten on the next commit (molecule's pre-commit hook regenerates).
|
|
5
|
+
To change this document, edit the module-level JSDoc in src/index.ts.
|
|
6
|
+
Generated: 2026-11-18T23:41:33.125Z
|
|
7
|
+
-->
|
|
2
8
|
|
|
3
|
-
|
|
9
|
+
# @molecule/app-auth-brand-header-solid
|
|
10
|
+
|
|
11
|
+
Solid auth-page brand header.
|
|
12
|
+
|
|
13
|
+
Exports `AuthBrandHeader` — a centered wrapper holding a gradient
|
|
14
|
+
material-symbol chip + wordmark + tagline. Two modes: preset (pass
|
|
15
|
+
`appName` / `tagline` / `icon` and the default chip + wordmark + tagline
|
|
16
|
+
render) or composed (pass children built from the exported
|
|
17
|
+
`AuthBrandHeaderChip`, `AuthBrandHeaderWordmark`, and
|
|
18
|
+
`AuthBrandHeaderTagline` sub-components — preset props are then ignored).
|
|
19
|
+
|
|
20
|
+
It is the Solid counterpart of `@molecule/app-auth-brand-header-react`: same
|
|
21
|
+
props and the same DOM for the same input.
|
|
22
|
+
|
|
23
|
+
> **Auto-generated, AI-first package reference** for the [molecule.dev](https://molecule.dev) ecosystem.
|
|
24
|
+
> It is written to be read by coding agents as much as by people, and is generated from this
|
|
25
|
+
> package's source — edit `src/index.ts` JSDoc, not this file.
|
|
26
|
+
|
|
27
|
+
## Quick Start
|
|
28
|
+
|
|
29
|
+
```tsx
|
|
30
|
+
import { AuthBrandHeader } from '@molecule/app-auth-brand-header-solid'
|
|
31
|
+
import { APP_NAME, APP_TAGLINE } from './branding'
|
|
32
|
+
|
|
33
|
+
export function MyAuthHeader() {
|
|
34
|
+
return (
|
|
35
|
+
<AuthBrandHeader
|
|
36
|
+
appName={APP_NAME}
|
|
37
|
+
tagline={APP_TAGLINE}
|
|
38
|
+
icon="gavel"
|
|
39
|
+
chipGradient="linear-gradient(135deg, #e05a2b, #f06a3b)"
|
|
40
|
+
wordmarkColor="#e05a2b"
|
|
41
|
+
/>
|
|
42
|
+
)
|
|
43
|
+
}
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
## Type
|
|
47
|
+
|
|
48
|
+
`feature`
|
|
49
|
+
|
|
50
|
+
## Installation
|
|
51
|
+
|
|
52
|
+
```bash
|
|
53
|
+
npm install @molecule/app-auth-brand-header-solid @molecule/app-solid @molecule/app-ui @molecule/app-ui-solid solid-js
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
## API
|
|
57
|
+
|
|
58
|
+
### Interfaces
|
|
59
|
+
|
|
60
|
+
#### `AuthBrandHeaderChipProps`
|
|
61
|
+
|
|
62
|
+
Props accepted by the {@link AuthBrandHeaderChip} component.
|
|
63
|
+
|
|
64
|
+
```typescript
|
|
65
|
+
interface AuthBrandHeaderChipProps {
|
|
66
|
+
/** Material-symbol icon name shown inside the chip. */
|
|
67
|
+
icon: string
|
|
68
|
+
/**
|
|
69
|
+
* CSS background value for the chip — typically a `linear-gradient(...)`.
|
|
70
|
+
* Falls back to the wired ClassMap's `bg-primary` token when omitted, so
|
|
71
|
+
* the chip's white icon glyph always has a colored backdrop.
|
|
72
|
+
*/
|
|
73
|
+
chipGradient?: string
|
|
74
|
+
/** Chip corner shape. `'round'` = `rounded-full`, `'square'` = `rounded-2xl`. */
|
|
75
|
+
chipShape?: 'round' | 'square'
|
|
76
|
+
}
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
#### `AuthBrandHeaderWordmarkProps`
|
|
80
|
+
|
|
81
|
+
Props accepted by the {@link AuthBrandHeaderWordmark} component.
|
|
82
|
+
|
|
83
|
+
```typescript
|
|
84
|
+
interface AuthBrandHeaderWordmarkProps {
|
|
85
|
+
/** The wordmark content — the brand name, or bespoke accented nodes. */
|
|
86
|
+
children?: JSX.Element
|
|
87
|
+
/** Inline color for the `<h1>`. */
|
|
88
|
+
color?: string
|
|
89
|
+
/** Extra classes appended to the default wordmark `<h1>` chrome. */
|
|
90
|
+
className?: string
|
|
91
|
+
}
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
#### `AuthBrandHeaderTaglineProps`
|
|
95
|
+
|
|
96
|
+
Props accepted by the {@link AuthBrandHeaderTagline} component.
|
|
97
|
+
|
|
98
|
+
```typescript
|
|
99
|
+
interface AuthBrandHeaderTaglineProps {
|
|
100
|
+
/** The tagline content. */
|
|
101
|
+
children?: JSX.Element
|
|
102
|
+
/** Extra classes appended to the default tagline `<p>` chrome. */
|
|
103
|
+
className?: string
|
|
104
|
+
}
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
#### `AuthBrandHeaderProps`
|
|
108
|
+
|
|
109
|
+
Props accepted by the {@link AuthBrandHeader} component.
|
|
110
|
+
|
|
111
|
+
Pass `children` to compose the header from {@link AuthBrandHeaderChip} /
|
|
112
|
+
{@link AuthBrandHeaderWordmark} / {@link AuthBrandHeaderTagline} (or bespoke
|
|
113
|
+
nodes). Omit it to use preset mode — the `appName` / `tagline` / `icon`
|
|
114
|
+
props render the default chip + wordmark + tagline.
|
|
115
|
+
|
|
116
|
+
```typescript
|
|
117
|
+
interface AuthBrandHeaderProps {
|
|
118
|
+
/**
|
|
119
|
+
* Composed header content. When set, the preset props below are ignored and
|
|
120
|
+
* the content renders inside the centered wrapper `<div>`.
|
|
121
|
+
*/
|
|
122
|
+
children?: JSX.Element
|
|
123
|
+
/** Extra classes appended to the wrapper `<div>`. */
|
|
124
|
+
className?: string
|
|
125
|
+
/** Brand name for the default wordmark. */
|
|
126
|
+
appName?: string
|
|
127
|
+
/** Tagline for the default tagline line. */
|
|
128
|
+
tagline?: string
|
|
129
|
+
/** Material-symbol icon name for the default chip (omit for no chip). */
|
|
130
|
+
icon?: string
|
|
131
|
+
/** CSS background for the default chip. */
|
|
132
|
+
chipGradient?: string
|
|
133
|
+
/** Default chip corner shape. */
|
|
134
|
+
chipShape?: 'round' | 'square'
|
|
135
|
+
/** Inline color for the default wordmark `<h1>`. */
|
|
136
|
+
wordmarkColor?: string
|
|
137
|
+
}
|
|
138
|
+
```
|
|
139
|
+
|
|
140
|
+
### Functions
|
|
141
|
+
|
|
142
|
+
#### `AuthBrandHeaderChip(props)`
|
|
143
|
+
|
|
144
|
+
The gradient material-symbols chip shown above the wordmark.
|
|
145
|
+
|
|
146
|
+
```typescript
|
|
147
|
+
function AuthBrandHeaderChip(props: AuthBrandHeaderChipProps): JSX.Element
|
|
148
|
+
```
|
|
149
|
+
|
|
150
|
+
- `props` — Component props (see {@link AuthBrandHeaderChipProps}).
|
|
151
|
+
|
|
152
|
+
**Returns:** The chip.
|
|
153
|
+
|
|
154
|
+
#### `AuthBrandHeaderWordmark(props)`
|
|
155
|
+
|
|
156
|
+
The wordmark `<h1>`. Pass the brand name (or bespoke accented nodes) as
|
|
157
|
+
children; `className` appends to the default `4xl` extra-bold treatment,
|
|
158
|
+
`color` sets an inline color.
|
|
159
|
+
|
|
160
|
+
```typescript
|
|
161
|
+
function AuthBrandHeaderWordmark(props: AuthBrandHeaderWordmarkProps): JSX.Element
|
|
162
|
+
```
|
|
163
|
+
|
|
164
|
+
- `props` — Component props (see {@link AuthBrandHeaderWordmarkProps}).
|
|
165
|
+
|
|
166
|
+
**Returns:** The wordmark.
|
|
167
|
+
|
|
168
|
+
#### `AuthBrandHeaderTagline(props)`
|
|
169
|
+
|
|
170
|
+
The tagline `<p>`. Pass the tagline text as children; `className` appends to
|
|
171
|
+
the default small muted treatment.
|
|
172
|
+
|
|
173
|
+
```typescript
|
|
174
|
+
function AuthBrandHeaderTagline(props: AuthBrandHeaderTaglineProps): JSX.Element
|
|
175
|
+
```
|
|
176
|
+
|
|
177
|
+
- `props` — Component props (see {@link AuthBrandHeaderTaglineProps}).
|
|
178
|
+
|
|
179
|
+
**Returns:** The tagline.
|
|
180
|
+
|
|
181
|
+
#### `AuthBrandHeader(props)`
|
|
182
|
+
|
|
183
|
+
Centered auth-page brand header supporting both composable children and
|
|
184
|
+
preset mode.
|
|
185
|
+
|
|
186
|
+
```typescript
|
|
187
|
+
function AuthBrandHeader(props: AuthBrandHeaderProps): JSX.Element
|
|
188
|
+
```
|
|
189
|
+
|
|
190
|
+
- `props` — Component props (see {@link AuthBrandHeaderProps}).
|
|
191
|
+
|
|
192
|
+
**Returns:** The brand header.
|
|
193
|
+
|
|
194
|
+
## Injection Notes
|
|
195
|
+
|
|
196
|
+
### Requirements
|
|
197
|
+
|
|
198
|
+
Peer dependencies:
|
|
199
|
+
|
|
200
|
+
- `@molecule/app-solid` ^3.5.0
|
|
201
|
+
- `@molecule/app-ui` ^1.3.11
|
|
202
|
+
- `@molecule/app-ui-solid` ^1.1.0
|
|
203
|
+
- `solid-js` ^1.8.0
|
|
204
|
+
|
|
205
|
+
### Runtime Dependencies
|
|
206
|
+
|
|
207
|
+
- `@molecule/app-solid`
|
|
208
|
+
- `@molecule/app-ui`
|
|
209
|
+
- `@molecule/app-ui-solid`
|
|
210
|
+
- `solid-js`
|
|
211
|
+
|
|
212
|
+
`icon` is a Material Symbols name rendered with the
|
|
213
|
+
`material-symbols-outlined` icon font — the app must load that font
|
|
214
|
+
(molecule scaffolds do; a custom stack must add it) or the icon name
|
|
215
|
+
renders as literal text. Omit `icon` to skip the chip entirely. The
|
|
216
|
+
default chip/wordmark treatment uses Tailwind theme tokens
|
|
217
|
+
(`bg-primary`, `text-on-surface`) from the wired ClassMap bond — with a
|
|
218
|
+
non-Tailwind ClassMap, pass `chipGradient` / `wordmarkColor` / `className`
|
|
219
|
+
explicitly.
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Solid auth-page brand header — a centered `<div>` wrapper holding a gradient
|
|
3
|
+
* chip + wordmark + tagline.
|
|
4
|
+
*
|
|
5
|
+
* Solid counterpart of `@molecule/app-auth-brand-header-react`'s components —
|
|
6
|
+
* the same props (React names), the same ClassMap tokens, and the same DOM for
|
|
7
|
+
* the same input.
|
|
8
|
+
*
|
|
9
|
+
* @module
|
|
10
|
+
*/
|
|
11
|
+
import { type Component } from 'solid-js';
|
|
12
|
+
import type { AuthBrandHeaderChipProps, AuthBrandHeaderProps, AuthBrandHeaderTaglineProps, AuthBrandHeaderWordmarkProps } from './types.js';
|
|
13
|
+
/**
|
|
14
|
+
* The gradient material-symbols chip shown above the wordmark.
|
|
15
|
+
*
|
|
16
|
+
* @param props - Component props (see {@link AuthBrandHeaderChipProps}).
|
|
17
|
+
* @returns The chip.
|
|
18
|
+
*/
|
|
19
|
+
export declare const AuthBrandHeaderChip: Component<AuthBrandHeaderChipProps>;
|
|
20
|
+
/**
|
|
21
|
+
* The wordmark `<h1>`. Pass the brand name (or bespoke accented nodes) as
|
|
22
|
+
* children; `className` appends to the default `4xl` extra-bold treatment,
|
|
23
|
+
* `color` sets an inline color.
|
|
24
|
+
*
|
|
25
|
+
* @param props - Component props (see {@link AuthBrandHeaderWordmarkProps}).
|
|
26
|
+
* @returns The wordmark.
|
|
27
|
+
*/
|
|
28
|
+
export declare const AuthBrandHeaderWordmark: Component<AuthBrandHeaderWordmarkProps>;
|
|
29
|
+
/**
|
|
30
|
+
* The tagline `<p>`. Pass the tagline text as children; `className` appends to
|
|
31
|
+
* the default small muted treatment.
|
|
32
|
+
*
|
|
33
|
+
* @param props - Component props (see {@link AuthBrandHeaderTaglineProps}).
|
|
34
|
+
* @returns The tagline.
|
|
35
|
+
*/
|
|
36
|
+
export declare const AuthBrandHeaderTagline: Component<AuthBrandHeaderTaglineProps>;
|
|
37
|
+
/**
|
|
38
|
+
* Centered auth-page brand header supporting both composable children and
|
|
39
|
+
* preset mode.
|
|
40
|
+
*
|
|
41
|
+
* @param props - Component props (see {@link AuthBrandHeaderProps}).
|
|
42
|
+
* @returns The brand header.
|
|
43
|
+
*/
|
|
44
|
+
export declare const AuthBrandHeader: Component<AuthBrandHeaderProps>;
|
|
45
|
+
//# sourceMappingURL=AuthBrandHeader.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AuthBrandHeader.d.ts","sourceRoot":"","sources":["../src/AuthBrandHeader.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,EAAE,KAAK,SAAS,EAAQ,MAAM,UAAU,CAAA;AAK/C,OAAO,KAAK,EACV,wBAAwB,EACxB,oBAAoB,EACpB,2BAA2B,EAC3B,4BAA4B,EAC7B,MAAM,YAAY,CAAA;AAEnB;;;;;GAKG;AACH,eAAO,MAAM,mBAAmB,EAAE,SAAS,CAAC,wBAAwB,CA0BnE,CAAA;AAED;;;;;;;GAOG;AACH,eAAO,MAAM,uBAAuB,EAAE,SAAS,CAAC,4BAA4B,CAU3E,CAAA;AAED;;;;;;GAMG;AACH,eAAO,MAAM,sBAAsB,EAAE,SAAS,CAAC,2BAA2B,CAczE,CAAA;AAED;;;;;;GAMG;AACH,eAAO,MAAM,eAAe,EAAE,SAAS,CAAC,oBAAoB,CAqC3D,CAAA"}
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Solid auth-page brand header — a centered `<div>` wrapper holding a gradient
|
|
3
|
+
* chip + wordmark + tagline.
|
|
4
|
+
*
|
|
5
|
+
* Solid counterpart of `@molecule/app-auth-brand-header-react`'s components —
|
|
6
|
+
* the same props (React names), the same ClassMap tokens, and the same DOM for
|
|
7
|
+
* the same input.
|
|
8
|
+
*
|
|
9
|
+
* @module
|
|
10
|
+
*/
|
|
11
|
+
import { Show } from 'solid-js';
|
|
12
|
+
import { useTranslation } from '@molecule/app-solid';
|
|
13
|
+
import { getClassMap } from '@molecule/app-ui';
|
|
14
|
+
/**
|
|
15
|
+
* The gradient material-symbols chip shown above the wordmark.
|
|
16
|
+
*
|
|
17
|
+
* @param props - Component props (see {@link AuthBrandHeaderChipProps}).
|
|
18
|
+
* @returns The chip.
|
|
19
|
+
*/
|
|
20
|
+
export const AuthBrandHeaderChip = (props) => {
|
|
21
|
+
const cm = getClassMap();
|
|
22
|
+
const shape = () => props.chipShape ?? 'round';
|
|
23
|
+
return (<div class={cm.cn(cm.w(12), cm.h(12), shape() === 'round' ? cm.roundedFull : '', cm.flex({ align: 'center', justify: 'center' }), cm.sp('mb', 2), shape() === 'square' ? cm.authBrandHeaderChipSquare : '', props.chipGradient ? '' : cm.bgPrimary, cm.authBrandHeaderChipShadow)} style={props.chipGradient ? { background: props.chipGradient } : undefined}>
|
|
24
|
+
<span class={cm.cn(cm.textSize('3xl'), cm.iconGlyphFont, cm.authBrandHeaderChipIcon)} style={{ 'font-variation-settings': "'FILL' 1" }} aria-hidden="true">
|
|
25
|
+
{props.icon}
|
|
26
|
+
</span>
|
|
27
|
+
</div>);
|
|
28
|
+
};
|
|
29
|
+
/**
|
|
30
|
+
* The wordmark `<h1>`. Pass the brand name (or bespoke accented nodes) as
|
|
31
|
+
* children; `className` appends to the default `4xl` extra-bold treatment,
|
|
32
|
+
* `color` sets an inline color.
|
|
33
|
+
*
|
|
34
|
+
* @param props - Component props (see {@link AuthBrandHeaderWordmarkProps}).
|
|
35
|
+
* @returns The wordmark.
|
|
36
|
+
*/
|
|
37
|
+
export const AuthBrandHeaderWordmark = (props) => {
|
|
38
|
+
const cm = getClassMap();
|
|
39
|
+
return (<h1 class={cm.cn(cm.textSize('4xl'), cm.authBrandHeaderWordmark, props.className)} style={props.color ? { color: props.color } : undefined}>
|
|
40
|
+
{props.children}
|
|
41
|
+
</h1>);
|
|
42
|
+
};
|
|
43
|
+
/**
|
|
44
|
+
* The tagline `<p>`. Pass the tagline text as children; `className` appends to
|
|
45
|
+
* the default small muted treatment.
|
|
46
|
+
*
|
|
47
|
+
* @param props - Component props (see {@link AuthBrandHeaderTaglineProps}).
|
|
48
|
+
* @returns The tagline.
|
|
49
|
+
*/
|
|
50
|
+
export const AuthBrandHeaderTagline = (props) => {
|
|
51
|
+
const cm = getClassMap();
|
|
52
|
+
return (<p class={cm.cn(cm.textSize('sm'), cm.fontWeight('medium'), cm.authBrandHeaderTagline, props.className)}>
|
|
53
|
+
{props.children}
|
|
54
|
+
</p>);
|
|
55
|
+
};
|
|
56
|
+
/**
|
|
57
|
+
* Centered auth-page brand header supporting both composable children and
|
|
58
|
+
* preset mode.
|
|
59
|
+
*
|
|
60
|
+
* @param props - Component props (see {@link AuthBrandHeaderProps}).
|
|
61
|
+
* @returns The brand header.
|
|
62
|
+
*/
|
|
63
|
+
export const AuthBrandHeader = (props) => {
|
|
64
|
+
const cm = getClassMap();
|
|
65
|
+
const { t } = useTranslation();
|
|
66
|
+
const hasChildren = () => props.children !== undefined &&
|
|
67
|
+
props.children !== null &&
|
|
68
|
+
!(Array.isArray(props.children) && props.children.length === 0);
|
|
69
|
+
return (
|
|
70
|
+
// A `<div>`, not `<header>` — several hosts render their own top bar on
|
|
71
|
+
// auth screens; a second `<header>` here reads as a duplicated app bar.
|
|
72
|
+
// This block is brand intro content, not a banner.
|
|
73
|
+
<div class={cm.cn(cm.flex({ direction: 'col', align: 'center', gap: 'sm' }), props.className)}>
|
|
74
|
+
<Show when={!hasChildren()} fallback={props.children}>
|
|
75
|
+
{props.icon ? (<AuthBrandHeaderChip icon={props.icon} chipGradient={props.chipGradient} chipShape={props.chipShape}/>) : null}
|
|
76
|
+
<AuthBrandHeaderWordmark color={props.wordmarkColor}>
|
|
77
|
+
{t('authBrandHeader.appName', { appName: props.appName ?? '' }, { defaultValue: '{{appName}}' })}
|
|
78
|
+
</AuthBrandHeaderWordmark>
|
|
79
|
+
<AuthBrandHeaderTagline>
|
|
80
|
+
{t('authBrandHeader.tagline', { tagline: props.tagline ?? '' }, { defaultValue: '{{tagline}}' })}
|
|
81
|
+
</AuthBrandHeaderTagline>
|
|
82
|
+
</Show>
|
|
83
|
+
</div>);
|
|
84
|
+
};
|
|
85
|
+
//# sourceMappingURL=AuthBrandHeader.jsx.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AuthBrandHeader.jsx","sourceRoot":"","sources":["../src/AuthBrandHeader.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,EAAkB,IAAI,EAAE,MAAM,UAAU,CAAA;AAE/C,OAAO,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAA;AACpD,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAA;AAS9C;;;;;GAKG;AACH,MAAM,CAAC,MAAM,mBAAmB,GAAwC,CAAC,KAAK,EAAE,EAAE;IAChF,MAAM,EAAE,GAAG,WAAW,EAAE,CAAA;IACxB,MAAM,KAAK,GAAG,GAAuB,EAAE,CAAC,KAAK,CAAC,SAAS,IAAI,OAAO,CAAA;IAClE,OAAO,CACL,CAAC,G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
* Solid auth-page brand header.
|
|
3
|
+
*
|
|
4
|
+
* Exports `AuthBrandHeader` — a centered wrapper holding a gradient
|
|
5
|
+
* material-symbol chip + wordmark + tagline. Two modes: preset (pass
|
|
6
|
+
* `appName` / `tagline` / `icon` and the default chip + wordmark + tagline
|
|
7
|
+
* render) or composed (pass children built from the exported
|
|
8
|
+
* `AuthBrandHeaderChip`, `AuthBrandHeaderWordmark`, and
|
|
9
|
+
* `AuthBrandHeaderTagline` sub-components — preset props are then ignored).
|
|
10
|
+
*
|
|
11
|
+
* It is the Solid counterpart of `@molecule/app-auth-brand-header-react`: same
|
|
12
|
+
* props and the same DOM for the same input.
|
|
13
|
+
*
|
|
14
|
+
* @example
|
|
15
|
+
* ```tsx
|
|
16
|
+
* import { AuthBrandHeader } from '@molecule/app-auth-brand-header-solid'
|
|
17
|
+
* import { APP_NAME, APP_TAGLINE } from './branding'
|
|
18
|
+
*
|
|
19
|
+
* export function MyAuthHeader() {
|
|
20
|
+
* return (
|
|
21
|
+
* <AuthBrandHeader
|
|
22
|
+
* appName={APP_NAME}
|
|
23
|
+
* tagline={APP_TAGLINE}
|
|
24
|
+
* icon="gavel"
|
|
25
|
+
* chipGradient="linear-gradient(135deg, #e05a2b, #f06a3b)"
|
|
26
|
+
* wordmarkColor="#e05a2b"
|
|
27
|
+
* />
|
|
28
|
+
* )
|
|
29
|
+
* }
|
|
30
|
+
* ```
|
|
31
|
+
*
|
|
32
|
+
* @remarks
|
|
33
|
+
* `icon` is a Material Symbols name rendered with the
|
|
34
|
+
* `material-symbols-outlined` icon font — the app must load that font
|
|
35
|
+
* (molecule scaffolds do; a custom stack must add it) or the icon name
|
|
36
|
+
* renders as literal text. Omit `icon` to skip the chip entirely. The
|
|
37
|
+
* default chip/wordmark treatment uses Tailwind theme tokens
|
|
38
|
+
* (`bg-primary`, `text-on-surface`) from the wired ClassMap bond — with a
|
|
39
|
+
* non-Tailwind ClassMap, pass `chipGradient` / `wordmarkColor` / `className`
|
|
40
|
+
* explicitly.
|
|
41
|
+
*
|
|
42
|
+
* @module
|
|
43
|
+
*/
|
|
44
|
+
export * from './AuthBrandHeader.jsx';
|
|
45
|
+
export * from './types.js';
|
|
46
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0CG;AAEH,cAAc,uBAAuB,CAAA;AACrC,cAAc,YAAY,CAAA"}
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Solid auth-page brand header.
|
|
3
|
+
*
|
|
4
|
+
* Exports `AuthBrandHeader` — a centered wrapper holding a gradient
|
|
5
|
+
* material-symbol chip + wordmark + tagline. Two modes: preset (pass
|
|
6
|
+
* `appName` / `tagline` / `icon` and the default chip + wordmark + tagline
|
|
7
|
+
* render) or composed (pass children built from the exported
|
|
8
|
+
* `AuthBrandHeaderChip`, `AuthBrandHeaderWordmark`, and
|
|
9
|
+
* `AuthBrandHeaderTagline` sub-components — preset props are then ignored).
|
|
10
|
+
*
|
|
11
|
+
* It is the Solid counterpart of `@molecule/app-auth-brand-header-react`: same
|
|
12
|
+
* props and the same DOM for the same input.
|
|
13
|
+
*
|
|
14
|
+
* @example
|
|
15
|
+
* ```tsx
|
|
16
|
+
* import { AuthBrandHeader } from '@molecule/app-auth-brand-header-solid'
|
|
17
|
+
* import { APP_NAME, APP_TAGLINE } from './branding'
|
|
18
|
+
*
|
|
19
|
+
* export function MyAuthHeader() {
|
|
20
|
+
* return (
|
|
21
|
+
* <AuthBrandHeader
|
|
22
|
+
* appName={APP_NAME}
|
|
23
|
+
* tagline={APP_TAGLINE}
|
|
24
|
+
* icon="gavel"
|
|
25
|
+
* chipGradient="linear-gradient(135deg, #e05a2b, #f06a3b)"
|
|
26
|
+
* wordmarkColor="#e05a2b"
|
|
27
|
+
* />
|
|
28
|
+
* )
|
|
29
|
+
* }
|
|
30
|
+
* ```
|
|
31
|
+
*
|
|
32
|
+
* @remarks
|
|
33
|
+
* `icon` is a Material Symbols name rendered with the
|
|
34
|
+
* `material-symbols-outlined` icon font — the app must load that font
|
|
35
|
+
* (molecule scaffolds do; a custom stack must add it) or the icon name
|
|
36
|
+
* renders as literal text. Omit `icon` to skip the chip entirely. The
|
|
37
|
+
* default chip/wordmark treatment uses Tailwind theme tokens
|
|
38
|
+
* (`bg-primary`, `text-on-surface`) from the wired ClassMap bond — with a
|
|
39
|
+
* non-Tailwind ClassMap, pass `chipGradient` / `wordmarkColor` / `className`
|
|
40
|
+
* explicitly.
|
|
41
|
+
*
|
|
42
|
+
* @module
|
|
43
|
+
*/
|
|
44
|
+
export * from './AuthBrandHeader.jsx';
|
|
45
|
+
export * from './types.js';
|
|
46
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0CG;AAEH,cAAc,uBAAuB,CAAA;AACrC,cAAc,YAAY,CAAA"}
|
package/dist/types.d.ts
ADDED
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Types for the Solid auth-page brand header.
|
|
3
|
+
*
|
|
4
|
+
* Solid counterpart of `@molecule/app-auth-brand-header-react`'s prop types:
|
|
5
|
+
* the same prop names, with node-valued props typed as Solid JSX values.
|
|
6
|
+
*
|
|
7
|
+
* @module
|
|
8
|
+
*/
|
|
9
|
+
import type { JSX } from 'solid-js';
|
|
10
|
+
/**
|
|
11
|
+
* Props accepted by the {@link AuthBrandHeaderChip} component.
|
|
12
|
+
*/
|
|
13
|
+
export interface AuthBrandHeaderChipProps {
|
|
14
|
+
/** Material-symbol icon name shown inside the chip. */
|
|
15
|
+
icon: string;
|
|
16
|
+
/**
|
|
17
|
+
* CSS background value for the chip — typically a `linear-gradient(...)`.
|
|
18
|
+
* Falls back to the wired ClassMap's `bg-primary` token when omitted, so
|
|
19
|
+
* the chip's white icon glyph always has a colored backdrop.
|
|
20
|
+
*/
|
|
21
|
+
chipGradient?: string;
|
|
22
|
+
/** Chip corner shape. `'round'` = `rounded-full`, `'square'` = `rounded-2xl`. */
|
|
23
|
+
chipShape?: 'round' | 'square';
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Props accepted by the {@link AuthBrandHeaderWordmark} component.
|
|
27
|
+
*/
|
|
28
|
+
export interface AuthBrandHeaderWordmarkProps {
|
|
29
|
+
/** The wordmark content — the brand name, or bespoke accented nodes. */
|
|
30
|
+
children?: JSX.Element;
|
|
31
|
+
/** Inline color for the `<h1>`. */
|
|
32
|
+
color?: string;
|
|
33
|
+
/** Extra classes appended to the default wordmark `<h1>` chrome. */
|
|
34
|
+
className?: string;
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* Props accepted by the {@link AuthBrandHeaderTagline} component.
|
|
38
|
+
*/
|
|
39
|
+
export interface AuthBrandHeaderTaglineProps {
|
|
40
|
+
/** The tagline content. */
|
|
41
|
+
children?: JSX.Element;
|
|
42
|
+
/** Extra classes appended to the default tagline `<p>` chrome. */
|
|
43
|
+
className?: string;
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Props accepted by the {@link AuthBrandHeader} component.
|
|
47
|
+
*
|
|
48
|
+
* Pass `children` to compose the header from {@link AuthBrandHeaderChip} /
|
|
49
|
+
* {@link AuthBrandHeaderWordmark} / {@link AuthBrandHeaderTagline} (or bespoke
|
|
50
|
+
* nodes). Omit it to use preset mode — the `appName` / `tagline` / `icon`
|
|
51
|
+
* props render the default chip + wordmark + tagline.
|
|
52
|
+
*/
|
|
53
|
+
export interface AuthBrandHeaderProps {
|
|
54
|
+
/**
|
|
55
|
+
* Composed header content. When set, the preset props below are ignored and
|
|
56
|
+
* the content renders inside the centered wrapper `<div>`.
|
|
57
|
+
*/
|
|
58
|
+
children?: JSX.Element;
|
|
59
|
+
/** Extra classes appended to the wrapper `<div>`. */
|
|
60
|
+
className?: string;
|
|
61
|
+
/** Brand name for the default wordmark. */
|
|
62
|
+
appName?: string;
|
|
63
|
+
/** Tagline for the default tagline line. */
|
|
64
|
+
tagline?: string;
|
|
65
|
+
/** Material-symbol icon name for the default chip (omit for no chip). */
|
|
66
|
+
icon?: string;
|
|
67
|
+
/** CSS background for the default chip. */
|
|
68
|
+
chipGradient?: string;
|
|
69
|
+
/** Default chip corner shape. */
|
|
70
|
+
chipShape?: 'round' | 'square';
|
|
71
|
+
/** Inline color for the default wordmark `<h1>`. */
|
|
72
|
+
wordmarkColor?: string;
|
|
73
|
+
}
|
|
74
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,UAAU,CAAA;AAEnC;;GAEG;AACH,MAAM,WAAW,wBAAwB;IACvC,uDAAuD;IACvD,IAAI,EAAE,MAAM,CAAA;IACZ;;;;OAIG;IACH,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,iFAAiF;IACjF,SAAS,CAAC,EAAE,OAAO,GAAG,QAAQ,CAAA;CAC/B;AAED;;GAEG;AACH,MAAM,WAAW,4BAA4B;IAC3C,wEAAwE;IACxE,QAAQ,CAAC,EAAE,GAAG,CAAC,OAAO,CAAA;IACtB,mCAAmC;IACnC,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,oEAAoE;IACpE,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAED;;GAEG;AACH,MAAM,WAAW,2BAA2B;IAC1C,2BAA2B;IAC3B,QAAQ,CAAC,EAAE,GAAG,CAAC,OAAO,CAAA;IACtB,kEAAkE;IAClE,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAED;;;;;;;GAOG;AACH,MAAM,WAAW,oBAAoB;IACnC;;;OAGG;IACH,QAAQ,CAAC,EAAE,GAAG,CAAC,OAAO,CAAA;IACtB,qDAAqD;IACrD,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,2CAA2C;IAC3C,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,4CAA4C;IAC5C,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,yEAAyE;IACzE,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,2CAA2C;IAC3C,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,iCAAiC;IACjC,SAAS,CAAC,EAAE,OAAO,GAAG,QAAQ,CAAA;IAC9B,oDAAoD;IACpD,aAAa,CAAC,EAAE,MAAM,CAAA;CACvB"}
|
package/dist/types.js
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Types for the Solid auth-page brand header.
|
|
3
|
+
*
|
|
4
|
+
* Solid counterpart of `@molecule/app-auth-brand-header-react`'s prop types:
|
|
5
|
+
* the same prop names, with node-valued props typed as Solid JSX values.
|
|
6
|
+
*
|
|
7
|
+
* @module
|
|
8
|
+
*/
|
|
9
|
+
export {};
|
|
10
|
+
//# sourceMappingURL=types.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,66 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@molecule/app-auth-brand-header-solid",
|
|
3
|
-
"version": "
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
|
|
3
|
+
"version": "1.1.0",
|
|
4
|
+
"description": "Brand header for auth pages — gradient material-symbol chip + large wordmark + tagline.",
|
|
5
|
+
"homepage": "https://www.molecule.dev/packages/app-auth-brand-header-solid",
|
|
6
|
+
"type": "module",
|
|
7
|
+
"main": "dist/index.js",
|
|
8
|
+
"types": "dist/index.d.ts",
|
|
9
|
+
"exports": {
|
|
10
|
+
".": {
|
|
11
|
+
"types": "./dist/index.d.ts",
|
|
12
|
+
"import": "./dist/index.js"
|
|
13
|
+
}
|
|
14
|
+
},
|
|
15
|
+
"files": [
|
|
16
|
+
"dist",
|
|
17
|
+
"README.md"
|
|
18
|
+
],
|
|
19
|
+
"scripts": {
|
|
20
|
+
"build": "tsc",
|
|
21
|
+
"dev": "tsc --watch",
|
|
22
|
+
"test": "vitest run",
|
|
23
|
+
"test:watch": "vitest"
|
|
24
|
+
},
|
|
25
|
+
"keywords": [
|
|
26
|
+
"molecule",
|
|
27
|
+
"auth",
|
|
28
|
+
"brand",
|
|
29
|
+
"header",
|
|
30
|
+
"solid"
|
|
31
|
+
],
|
|
32
|
+
"author": "Molecule Dev, Inc. (https://molecule.dev)",
|
|
33
|
+
"license": "Apache-2.0",
|
|
34
|
+
"repository": {
|
|
35
|
+
"type": "git",
|
|
36
|
+
"url": "https://github.com/molecule-dev/molecule.git",
|
|
37
|
+
"directory": "packages/app/features/auth-brand-header-solid"
|
|
38
|
+
},
|
|
39
|
+
"engines": {
|
|
40
|
+
"node": ">=20"
|
|
41
|
+
},
|
|
42
|
+
"bugs": "https://github.com/molecule-dev/molecule/issues",
|
|
43
|
+
"publishConfig": {
|
|
44
|
+
"access": "public"
|
|
45
|
+
},
|
|
46
|
+
"peerDependencies": {
|
|
47
|
+
"@molecule/app-solid": "^3.5.0",
|
|
48
|
+
"@molecule/app-ui": "^1.3.11",
|
|
49
|
+
"@molecule/app-ui-solid": "^1.1.0",
|
|
50
|
+
"solid-js": "^1.8.0"
|
|
51
|
+
},
|
|
52
|
+
"devDependencies": {
|
|
53
|
+
"@molecule/app-framework-conformance": "0.0.0",
|
|
54
|
+
"@molecule/app-i18n": "1.2.2",
|
|
55
|
+
"@molecule/app-icons": "1.0.4",
|
|
56
|
+
"@molecule/app-solid": "3.7.2",
|
|
57
|
+
"@molecule/app-ui": "1.4.0",
|
|
58
|
+
"@molecule/app-ui-solid": "1.1.5",
|
|
59
|
+
"@types/node": "26.6.5",
|
|
60
|
+
"jsdom": "30.1.3",
|
|
61
|
+
"solid-js": "1.9.17",
|
|
62
|
+
"typescript": "6.0.3",
|
|
63
|
+
"vite-plugin-solid": "2.11.15",
|
|
64
|
+
"vitest": "4.1.12"
|
|
65
|
+
}
|
|
66
|
+
}
|