GlassKit Elements
Complete reference for all 24 web components – built by Jungherz GmbH. Vanilla JS, Shadow DOM, native form participation.
Installation
CDN (quickest)
npm
Selective Import
Import only what you need for smaller bundles:
Theming
Set data-theme on the <html> element. All components sync automatically via a shared MutationObserver.
Form Integration
All form components participate in native forms via ElementInternals.
Content Components
<glk-title>
Styled heading with text shadow.
<glk-badge>
Inline status badge with color variants.
| Attribute | Type | Values |
|---|---|---|
variant | String | primary | success | error |
<glk-avatar>
Circular avatar with initials or image.
| Attribute | Type | Values |
|---|---|---|
size | String | sm | (default) | lg |
src | String | Image URL |
<glk-card>
Glass-effect content card.
| Attribute | Type | Description |
|---|---|---|
glow | Boolean | Adds gradient glow effect |
<glk-divider>
<glk-status>
Status notice with message.
Buttons
<glk-button>
Glass-styled button with three variants and size options.
| Attribute | Type | Values |
|---|---|---|
variant | String | primary | secondary | tertiary |
size | String | sm | md | lg | auto |
disabled | Boolean | Disables the button |
type | String | button | submit | reset |
Events: glk-click
<glk-pill>
Small circular icon button (46x46px).
| Attribute | Type | Description |
|---|---|---|
label | String | Accessible aria-label |
disabled | Boolean | Disables the button |
Form Components
All form components support name, value, disabled and participate in native <form> submission.
<glk-input>
Text input with label, hint, and error state.
| Attribute | Type | Description |
|---|---|---|
label | String | Input label |
type | String | text, email, password, ... |
placeholder | String | Placeholder text |
hint | String | Helper text |
error | Boolean | Error styling |
required | Boolean | Required field |
Events: glk-input, glk-change
<glk-textarea>
<glk-select>
<glk-search>
<glk-toggle>
Switch toggle with form participation.
| Attribute | Type | Description |
|---|---|---|
label | String | Toggle label |
checked | Boolean | Checked state |
disabled | Boolean | Disabled state |
Events: glk-change → { checked: boolean }
<glk-checkbox>
<glk-radio>
<glk-range>
| Attribute | Type | Description |
|---|---|---|
min | Number | Minimum (default: 0) |
max | Number | Maximum (default: 100) |
value | Number | Current value |
step | Number | Step increment |
Feedback
<glk-progress>
| Attribute | Type | Values |
|---|---|---|
value | Number | 0 – 100 |
variant | String | success | error |
size | String | sm | (default) | lg |
<glk-modal>
Modal dialog with title, body, and action buttons.
Are you sure you want to proceed?
| Attribute | Type | Description |
|---|---|---|
open | Boolean | Show/hide |
title | String | Header title |
Methods: .show(), .close() Events: glk-close
<glk-toast>
Auto-dismissing notification.
| Attribute | Type | Values |
|---|---|---|
variant | String | success | error | warning |
duration | Number | ms (default: 3000) |
Methods: .show(message, variant, duration), .dismiss()
Containers
<glk-accordion> + <glk-accordion-item>
Collapsible accordion sections.
| Attribute | Component | Description |
|---|---|---|
title | glk-accordion-item | Trigger text |
open | glk-accordion-item | Expanded state |
Events: glk-toggle → { open: boolean }