240 lines
6.9 KiB
Markdown
240 lines
6.9 KiB
Markdown
# @design.estate/dees-catalog
|
|
An extensive library for building modern web applications with dynamic components using Web Components, JavaScript, and TypeScript.
|
|
|
|
## Install
|
|
To install the `@design.estate/dees-catalog` library, you can use npm or any other compatible JavaScript package manager. Using npm is recommended:
|
|
|
|
```bash
|
|
npm install @design.estate/dees-catalog
|
|
```
|
|
|
|
## Usage
|
|
To use the components provided by `@design.estate/dees-catalog`, you need to import them into your project. Here's an example of how to import and use the `DeesButton` component:
|
|
|
|
```typescript
|
|
import { DeesButton } from '@design.estate/dees-catalog';
|
|
|
|
const button = document.createElement('dees-button');
|
|
button.text = 'Click me';
|
|
button.type = 'highlighted'; // Options: normal, highlighted, discreet
|
|
button.status = 'pending'; // Options: normal, pending, success, error
|
|
|
|
document.body.appendChild(button);
|
|
```
|
|
|
|
## Components Overview
|
|
|
|
Below is a comprehensive list of all available components:
|
|
|
|
| Category | Components |
|
|
|----------|------------|
|
|
| Core UI | `DeesButton`, `DeesBadge`, `DeesChips`, `DeesIcon`, `DeesLabel`, `DeesSpinner`, `DeesToast` |
|
|
| Forms | `DeesForm`, `DeesInputText`, `DeesInputCheckbox`, `DeesInputDropdown`, `DeesInputRadio`, `DeesInputFileupload`, `DeesInputIban`, `DeesInputPhone`, `DeesInputQuantitySelector`, `DeesInputMultitoggle`, `DeesFormSubmit` |
|
|
| Layout | `DeesAppuiBase`, `DeesAppuiMainmenu`, `DeesAppuiMainselector`, `DeesAppuiMaincontent`, `DeesAppuiAppbar`, `DeesMobileNavigation` |
|
|
| Data Display | `DeesTable`, `DeesDataviewCodebox`, `DeesDataviewStatusobject`, `DeesPdf` |
|
|
| Visualization | `DeesChartArea`, `DeesChartLog` |
|
|
| Dialogs & Overlays | `DeesModal`, `DeesContextmenu`, `DeesSpeechbubble`, `DeesWindowlayer` |
|
|
| Navigation | `DeesStepper`, `DeesProgressbar` |
|
|
| Development | `DeesEditor`, `DeesEditorMarkdown`, `DeesTerminal`, `DeesUpdater` |
|
|
|
|
## Detailed Component Documentation
|
|
|
|
### Core UI Components
|
|
|
|
#### `DeesButton`
|
|
A versatile button component supporting multiple styles and states.
|
|
|
|
```typescript
|
|
const button = document.createElement('dees-button');
|
|
button.text = 'Click me';
|
|
button.type = 'highlighted'; // Options: normal, highlighted, discreet
|
|
button.status = 'pending'; // Options: normal, pending, success, error
|
|
```
|
|
|
|
#### `DeesBadge`
|
|
Display status indicators or counts with customizable styles.
|
|
|
|
```typescript
|
|
<dees-badge
|
|
type="success" // Options: default, primary, success, warning, error
|
|
text="New"
|
|
rounded
|
|
></dees-badge>
|
|
```
|
|
|
|
#### `DeesChips`
|
|
Interactive chips/tags with selection capabilities.
|
|
|
|
```typescript
|
|
<dees-chips
|
|
selectionMode="multiple" // Options: none, single, multiple
|
|
chipsAreRemovable
|
|
.selectableChips=${[
|
|
{ key: 'tag1', value: 'Important' },
|
|
{ key: 'tag2', value: 'Urgent' }
|
|
]}
|
|
></dees-chips>
|
|
```
|
|
|
|
### Form Components
|
|
|
|
#### `DeesForm`
|
|
Container component for form elements with built-in validation and data collection.
|
|
|
|
```typescript
|
|
<dees-form>
|
|
<dees-input-text required label="Username"></dees-input-text>
|
|
<dees-input-password label="Password"></dees-input-password>
|
|
<dees-form-submit>Submit</dees-form-submit>
|
|
</dees-form>
|
|
```
|
|
|
|
#### `DeesInputText`
|
|
Text input field with validation and formatting options.
|
|
|
|
```typescript
|
|
<dees-input-text
|
|
label="Email"
|
|
required
|
|
type="email"
|
|
placeholder="Enter your email"
|
|
></dees-input-text>
|
|
```
|
|
|
|
#### `DeesInputDropdown`
|
|
Dropdown selection component with search and multi-select capabilities.
|
|
|
|
```typescript
|
|
<dees-input-dropdown
|
|
label="Country"
|
|
.options=${[
|
|
{ key: 'us', option: 'United States' },
|
|
{ key: 'uk', option: 'United Kingdom' }
|
|
]}
|
|
></dees-input-dropdown>
|
|
```
|
|
|
|
### Layout Components
|
|
|
|
#### `DeesAppuiBase`
|
|
Base layout component for application structure.
|
|
|
|
```typescript
|
|
<dees-appui-base>
|
|
<dees-appui-mainmenu></dees-appui-mainmenu>
|
|
<dees-appui-maincontent></dees-appui-maincontent>
|
|
</dees-appui-base>
|
|
```
|
|
|
|
#### `DeesAppuiMainmenu`
|
|
Navigation menu component for application sidebar.
|
|
|
|
```typescript
|
|
<dees-appui-mainmenu
|
|
.menuItems=${[
|
|
{ label: 'Dashboard', icon: 'home' },
|
|
{ label: 'Settings', icon: 'cog' }
|
|
]}
|
|
></dees-appui-mainmenu>
|
|
```
|
|
|
|
### Data Display Components
|
|
|
|
#### `DeesTable`
|
|
Advanced table component with sorting, filtering, and row selection.
|
|
|
|
```typescript
|
|
<dees-table
|
|
.data=${tableData}
|
|
.columns=${[
|
|
{ key: 'name', label: 'Name' },
|
|
{ key: 'age', label: 'Age' }
|
|
]}
|
|
selectable
|
|
></dees-table>
|
|
```
|
|
|
|
### Visualization Components
|
|
|
|
#### `DeesChartArea`
|
|
Area chart component using ApexCharts.
|
|
|
|
```typescript
|
|
<dees-chart-area
|
|
.series=${[
|
|
{ name: 'Sales', data: [30, 40, 35, 50] }
|
|
]}
|
|
></dees-chart-area>
|
|
```
|
|
|
|
### Dialog Components
|
|
|
|
#### `DeesModal`
|
|
Modal dialog component with customizable content and actions.
|
|
|
|
```typescript
|
|
DeesModal.createAndShow({
|
|
heading: 'Confirm Action',
|
|
content: html`<p>Are you sure?</p>`,
|
|
menuOptions: [
|
|
{ name: 'Cancel', action: () => modal.destroy() },
|
|
{ name: 'Confirm', action: () => handleConfirm() }
|
|
]
|
|
});
|
|
```
|
|
|
|
### Development Components
|
|
|
|
#### `DeesEditor`
|
|
Code editor component based on Monaco Editor.
|
|
|
|
```typescript
|
|
<dees-editor
|
|
language="typescript"
|
|
.value=${codeString}
|
|
@change=${handleChange}
|
|
></dees-editor>
|
|
```
|
|
|
|
## Customization and Theming
|
|
|
|
Components can be customized using CSS custom properties and the built-in theme system. Example:
|
|
|
|
```css
|
|
dees-button {
|
|
--dees-button-background: #007bff;
|
|
--dees-button-color: white;
|
|
}
|
|
```
|
|
|
|
## Browser Support
|
|
|
|
The library supports modern browsers with Web Components implementation:
|
|
- Chrome (latest)
|
|
- Firefox (latest)
|
|
- Safari (latest)
|
|
- Edge (latest)
|
|
|
|
## Contributing
|
|
|
|
Please read our [Contributing Guidelines](CONTRIBUTING.md) for details on submitting pull requests.
|
|
|
|
## License and Legal Information
|
|
|
|
This repository contains open-source code that is licensed under the MIT License. A copy of the MIT License can be found in the [license](license) file within this repository.
|
|
|
|
**Please note:** The MIT License does not grant permission to use the trade names, trademarks, service marks, or product names of the project, except as required for reasonable and customary use in describing the origin of the work and reproducing the content of the NOTICE file.
|
|
|
|
### Trademarks
|
|
|
|
This project is owned and maintained by Task Venture Capital GmbH. The names and logos associated with Task Venture Capital GmbH and any related products or services are trademarks of Task Venture Capital GmbH and are not included within the scope of the MIT license granted herein. Use of these trademarks must comply with Task Venture Capital GmbH's Trademark Guidelines, and any usage must be approved in writing by Task Venture Capital GmbH.
|
|
|
|
### Company Information
|
|
|
|
Task Venture Capital GmbH
|
|
Registered at District court Bremen HRB 35230 HB, Germany
|
|
|
|
For any legal inquiries or if you require further information, please contact us via email at hello@task.vc.
|
|
|
|
By using this repository, you acknowledge that you have read this section, agree to comply with its terms, and understand that the licensing of the code does not imply endorsement by Task Venture Capital GmbH of any derivative works.
|