Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
48f81f7
started updating header style
timea-solid Mar 31, 2026
d935375
Merge branch 'main' into milestone2k
timea-solid Apr 1, 2026
e3158d4
header component
timea-solid Apr 7, 2026
dd5b22d
fixed web cmponents distribution
timea-solid Apr 9, 2026
274ae77
login and signup web components wired in header
timea-solid Apr 9, 2026
d041d1d
close to final design
timea-solid Apr 10, 2026
1ed16ed
help menu render depends on layout
timea-solid Apr 10, 2026
3bc2412
minor layout conditional css
timea-solid Apr 10, 2026
9699fae
propagate logout
timea-solid Apr 10, 2026
9046dfd
css improvement of loggedin header button
timea-solid Apr 10, 2026
a88cb70
Support path-based pod roots in header and footer helpers
bourgeoa Apr 11, 2026
0257e35
lint
bourgeoa Apr 11, 2026
884c8c0
update pane-registry
bourgeoa Apr 11, 2026
00d1cd7
navigation-toggle
bourgeoa Apr 12, 2026
626fd49
Update scripts/build-component-dts.mjs
timea-solid Apr 13, 2026
12b426a
Update src/utils/headerFooterHelpers.ts
timea-solid Apr 13, 2026
9d4d657
Update test/unit/index.test.ts
timea-solid Apr 13, 2026
1b0c781
fix tests
timea-solid Apr 13, 2026
c124a18
better watch
timea-solid Apr 13, 2026
2f8d31d
Potential fix for pull request finding
timea-solid Apr 13, 2026
9b1ea92
fixed global UI problem
timea-solid Apr 13, 2026
a07b23e
improved readme
timea-solid Apr 13, 2026
56f778f
Potential fix for pull request finding
timea-solid Apr 13, 2026
7451cc5
remove unused copy-webpack-plugin
timea-solid Apr 13, 2026
4e607fa
align readme with defaults
timea-solid Apr 13, 2026
440a20e
Merge branch 'milestone2k' of https://github.com/solidos/solid-ui int…
timea-solid Apr 13, 2026
d5bf92e
updated lock file for node 24
timea-solid Apr 13, 2026
fea7473
improved readme
timea-solid Apr 13, 2026
b0a11eb
fix typo in readme
timea-solid Apr 13, 2026
4d43fd6
fix issuer URL input
timea-solid Apr 13, 2026
74f3502
Fix Escape key handling in LoginButton popup to work regardless of focus
Copilot Apr 13, 2026
a8b9a09
leave UI global variable untouched, web components not added to globa…
timea-solid Apr 13, 2026
8f6afc8
added login and signup tests
timea-solid Apr 13, 2026
48b1b8b
Merge branch 'milestone2k' of https://github.com/solidos/solid-ui int…
timea-solid Apr 13, 2026
0016dbe
build improvements
timea-solid Apr 13, 2026
5c1c9c1
Merge branch 'main' into milestone2k
bourgeoa Apr 13, 2026
ffc854a
improve code based on claude PR reviews
timea-solid Apr 13, 2026
6410a72
improved watch
timea-solid Apr 13, 2026
9178c23
improved local dev
timea-solid Apr 13, 2026
d0b1da6
improved css for components
timea-solid Apr 14, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ docs/api
examples/storybook
.history/
docs/form-examples/solid-ui.js
.tsbuildinfo
71 changes: 69 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,12 @@ See [Forms introduction](./docs/FormsReadme.md) for UI vocabulary implementation
- [Use Directly in Browser](#use-directly-in-a-browser)
- [UMD Bundle](#umd-bundle-global-variable)
- [ESM Bundle](#esm-bundle-import-as-module)
- [Development](#development-new-components)
- [Web Components](#web-components)
- [solid-ui-header](#solid-ui-header)
- [Development](#development)
- [Testing](#adding-tests)
- [Further Documentation](#further-documentation)
- [Generative AI usage](#generative-ai-usage)


## Getting started
Expand Down Expand Up @@ -253,7 +256,46 @@ Use import maps for cleaner module specifiers:
</html>
```

### Development new components
## Web Components

solid-ui ships self-contained Lit-based custom elements as subpath exports. Each component is independently importable, registers its custom element on import, and ships its own styles encapsulated in a Shadow DOM.

> Component UMD bundles do not export a shared global like `window.UI`. They only register the custom element on import, while the legacy main bundle still provides the `UI` global.

### solid-ui-header

A header bar with branding, auth state (logged-out / logged-in), an account dropdown, and a desktop-only help menu.

**Subpath export:** `solid-ui/components/header`

```typescript
import { Header } from 'solid-ui/components/header'
import type { HeaderMenuItem, HeaderAccountMenuItem, HeaderAuthState } from 'solid-ui/components/header'
```

Importing this module automatically registers `<solid-ui-header>` as a custom element. See [src/v2/components/header/README.md](src/v2/components/header/README.md) for the full API reference and usage examples.

### Component build pipeline

Web components use a two-stage build to produce a clean public layout without exposing internal source paths:

1. **webpack** (`npm run build-dist`) bundles each component entrypoint and emits the runtime files to `dist/components/<name>/index.js` and `dist/components/<name>/index.esm.js`.
2. **tsc** (`npm run build-js`) emits declaration files mirroring the source tree, so they land at `dist/v2/components/<name>/index.d.ts`.
3. **`scripts/build-component-dts.mjs`** (runs automatically after tsc as part of `postbuild-js`) writes a thin re-export wrapper at `dist/components/<name>/index.d.ts`, bridging the tsc output to the public package location.

This keeps the `package.json` subpath export fully aligned:

```json
"./components/header": {
"types": "./dist/components/header/index.d.ts",
"import": "./dist/components/header/index.esm.js",
"require": "./dist/components/header/index.js"
}
```

Consumers never see the internal `v2` path; it is an implementation detail of the source tree.

## Development

When developing a component in solid-ui you can test it in isolation using storybook

Expand Down Expand Up @@ -286,3 +328,28 @@ The following document gives guidance on how to add and perform testing in solid
## Further documentation

- [Some code know-how](https://github.com/SolidOS/solidos/wiki/2.-Solid-UI-know-how)

## Generative AI usage
The SolidOS team is using GitHub Copilot integrated in Visual Studio Code.
We have added comments in the code to make it explicit which parts are 100% written by AI.

### Prompt usage history:

* Raptor mini: If I want to make the header a web component with a self contained CSS which only consumes CSS variables from a theme, how would I do this?

* Raptor mini: Go ahead and create a header web component, for backward compatibility keep the current code too.
In the new header component I need to be flexible and receive from consumer - the layout (mobile or desktop) and the theme (light or dark) and its according CSS variables for light to dark.

* Raptor mini: Propose code. how about webpack config for distribution?

* Raptor mini: pls add a readme in the component documenting it usage and test and all

* Raptor mini: the helpMenuList should be menu items inside the help icon drop down menu

* Raptor mini: When I am not logged in I want the header to display: Log in button and Sign Up button.
When the user is logged in, there is only one button, a drop down button called Accounts. The icon of the button is the avatar of the profile and it displays a list of available accounts of the user.
I want this all to be presented flexible in the component.

* Claude Sonnet 4.6: create a LitElement also for the signupButton in the SignupButton.ts based on the signup.js code and wire it into the header like you did the loginButton.

* Raptor mini: when we are on layout mobile we do not want to display the help menu at all.
2 changes: 2 additions & 0 deletions __mocks__/styleMock.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
// Jest mock for CSS imports
module.exports = {}
2 changes: 1 addition & 1 deletion babel.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ export default {
browsers: ['> 1%', 'last 3 versions', 'not dead']
}
}],
'@babel/preset-typescript',
['@babel/preset-typescript', { allowDeclareFields: true }],
],
plugins: [
'@babel/plugin-transform-runtime'
Expand Down
5 changes: 4 additions & 1 deletion jest.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,12 @@ export default {
'^.+\\.(mjs|[tj]sx?)$': ['babel-jest', { configFile: './babel.config.mjs' }],
},
transformIgnorePatterns: [
'<rootDir>/node_modules/(?!(lit-html|@noble/curves|@noble/hashes|@exodus/bytes|uuid|jsdom|parse5|@asamuzakjp/css-color|@csstools)/)',
'<rootDir>/node_modules/(?!(lit|lit-html|lit-element|@lit|@lit-labs|@lit-labs/ssr-dom-shim|@lit/reactive-element|@noble/curves|@noble/hashes|@exodus/bytes|uuid|jsdom|parse5|@asamuzakjp/css-color|@csstools)/)',
],
setupFilesAfterEnv: ['./test/helpers/setup.ts'],
moduleNameMapper: {
'^.+\\.css$': '<rootDir>/__mocks__/styleMock.js'
},
testMatch: ['**/?(*.)+(spec|test).[tj]s?(x)'],
roots: ['<rootDir>/src', '<rootDir>/test', '<rootDir>/__mocks__'],
}
Loading
Loading