### Month Mode Example Source: https://www.fraktonng.com/docs/calendar-navigator/features Example demonstrating month mode navigation with date selection and current date display. ```html ``` -------------------------------- ### Example with Labels and Value Formatting Source: https://www.fraktonng.com/docs/progress-bar/features Demonstrates combining labels, inline values, and custom formatting for non-percentage units within a card layout. Includes a guided badge. ```html

Labels and value formatting

Combine labels, inline values, and custom formatting for non-percentage units.

Guided
``` -------------------------------- ### Configurable Paginator Example Source: https://www.fraktonng.com/docs/paginator/features Shows different configurations of the paginator for various use cases. This example is suitable for demonstrating flexibility. ```html ``` -------------------------------- ### Form Integration Example Source: https://www.fraktonng.com/docs/calendar-navigator/features Example demonstrating how to integrate the calendar navigator with reactive forms and form validation. ```html
Selected: {{ dateForm.selectedDate().value() | date:'fullDate' }}
``` -------------------------------- ### Install Frakton NG Package Source: https://www.fraktonng.com/docs/components-actions-button--raised Install the Frakton NG library using npm. This is the first step to using any Frakton NG components. ```bash npm install frakton-ng ``` -------------------------------- ### Complete Progress Bar Example Source: https://www.fraktonng.com/docs/progress-bar/features Show a progress bar in a completed state. This example configures value, label, and other display properties. ```html ``` -------------------------------- ### Basic Paginator Example Source: https://www.fraktonng.com/docs/paginator/features A default paginator example with all features enabled. Allows navigation and page size adjustments. ```html ``` -------------------------------- ### Dynamic Mode Switching Example Source: https://www.fraktonng.com/docs/calendar-navigator/features Example showing dynamic mode switching between month and year navigation. Includes buttons to toggle mode and navigate to today. ```html
Selected: {{ internalDate() | date:'fullDate' }}
``` -------------------------------- ### Basic Calendar Navigator Setup Source: https://www.fraktonng.com/docs/calendar-navigator/features Basic setup for the calendar navigator component, setting the mode and current date. ```html ``` -------------------------------- ### Basic Textarea Usage Source: https://www.fraktonng.com/docs/textarea/features A fundamental example of using the fkt-textarea component with a label and placeholder. This serves as a starting point for capturing free-form text. ```html

Current value: {{ control().value() || '(empty)' }}

``` -------------------------------- ### Basic Navigator Example Source: https://www.fraktonng.com/docs/navigator/features A fundamental implementation of the navigator component, demonstrating simple previous/next navigation along with a counter state. ```html ``` -------------------------------- ### Multi-Theme Setup for Switching Source: https://www.fraktonng.com/docs/getting-started-theming-styling Include both light and dark theme CSS files in your project configuration to enable easy theme switching. ```json { "styles": [ "node_modules/frakton-ng/assets/styles.css", "node_modules/frakton-ng/assets/themes/light.css", "node_modules/frakton-ng/assets/themes/dark.css" ] } ``` -------------------------------- ### Item Navigation Example Source: https://www.fraktonng.com/docs/navigator/features Example for navigating through a list of items, including proper boundary detection. This snippet displays the current item's title and description, along with navigation controls. ```html

{{ currentItem().title }}

{{ currentItem().description }}

Item {{ currentIndex() + 1 }} of {{ items.length }}
``` -------------------------------- ### Page Navigation Example Source: https://www.fraktonng.com/docs/navigator/features Example for pagination-style navigation, including page numbers and navigation controls. This snippet displays the current page and total pages, with controls to move between them. ```html
Page {{ currentPage() }} of {{ totalPages() }}
``` -------------------------------- ### Basic Autocomplete Example Source: https://www.fraktonng.com/docs/autocomplete/features Demonstrates the basic implementation of the autocomplete component with predefined options, including search and selection. ```typescript ``` -------------------------------- ### Template Reference Examples Source: https://www.fraktonng.com/docs/table/features Provides examples of using ng-templates for custom cell rendering, including customer details and formatted amounts. ```HTML
{{ name }} order {{ since }}
${{ amount.toFixed(2) }} ``` -------------------------------- ### Date Navigation Example Source: https://www.fraktonng.com/docs/navigator/features Example for navigating through dates, ensuring proper handling of boundary conditions. This snippet includes custom content display and event handling for month navigation. ```html
{{ formattedDate() }}
``` -------------------------------- ### Responsive Paginator Example Source: https://www.fraktonng.com/docs/paginator/features Illustrates the responsive design of the paginator, which adapts to different screen sizes with mobile-friendly reordering. ```html ``` -------------------------------- ### Disabled State Navigation Example Source: https://www.fraktonng.com/docs/navigator/features Demonstrates dynamic enable/disable states for the navigator's buttons based on specific business logic. This example shows individual disabling of previous, next, or both buttons. ```html

Previous Disabled

Next Disabled

Both Disabled

``` -------------------------------- ### Basic Select Example Source: https://www.fraktonng.com/docs/select/features Demonstrates a basic select dropdown with options. Use this for simple selection scenarios where no pre-selection or special states are needed. ```html
Selected Value: {{ control().value() || 'None' }}
``` -------------------------------- ### Aligning Spacing Systems Source: https://www.fraktonng.com/docs/getting-started-migration-guides/features Example CSS showing how to align spacing systems between libraries like Bootstrap and Frakton NG using a common spacing unit. ```css /* Align spacing systems */ :root { --spacing-unit: 8px; /* Bootstrap spacing (if using Ng-Bootstrap) */ --bs-spacer: var(--spacing-unit); /* Frakton spacing */ --fkt-space-xs: calc(var(--spacing-unit) * 0.5); --fkt-space-sm: var(--spacing-unit); --fkt-space-md: calc(var(--spacing-unit) * 2); } ``` -------------------------------- ### Coordinating Theme Colors Source: https://www.fraktonng.com/docs/getting-started-migration-guides/features Example CSS demonstrating how to coordinate brand colors between different UI libraries (Material, Frakton NG) using CSS variables. ```css /* Coordinate colors between libraries */ :root { /* Your brand colors */ --brand-primary: #1976d2; --brand-accent: #ff4081; /* Material variables */ --mat-primary: var(--brand-primary); /* Frakton variables */ --fkt-color-primary: var(--brand-primary); --fkt-color-accent: var(--brand-accent); } ``` -------------------------------- ### Basic Calendar Usage Source: https://www.fraktonng.com/docs/calendar/features Demonstrates the basic setup of the FktCalendar component for date selection with month and year navigation. ```html
``` -------------------------------- ### Loading State Navigation Example Source: https://www.fraktonng.com/docs/navigator/features Illustrates navigation with loading states during asynchronous operations, such as data fetching. The navigator buttons are disabled while loading, and a spinner is shown. ```html
@if (isLoading()) {
Loading...
}
``` -------------------------------- ### Interactive Overlay with Shared State Source: https://www.fraktonng.com/docs/overlay/features An interactive overlay example demonstrating how changes within the overlay can update shared application state. ```html

Shared State


Counter: Items:
Changes made in overlays will update this shared state automatically.

``` -------------------------------- ### Frakton NG Button and Overlay Menu Example (After Migration) Source: https://www.fraktonng.com/docs/getting-started-migration-guides/features Illustrates the equivalent functionality using Frakton NG's button with a built-in loading state and an overlay service for a dropdown menu. ```typescript // After (Frakton NG) import {FktButtonComponent} from 'frakton-ng/button'; import {FktOverlayService} from 'frakton-ng/overlay'; @Component({ template: ` `, imports: [FktButtonComponent] }) export class ExampleComponent { constructor(private overlay: FktOverlayService) { } openMenu(event: Event) { this.overlay.open({ anchorElementRef: {nativeElement: event.target as HTMLElement}, component: ActionsMenuComponent, data: { onEdit: () => this.edit(), onDelete: () => this.delete() } }); } } ``` -------------------------------- ### Vertical Divider Variants Example Source: https://www.fraktonng.com/docs/divider/features Illustrates vertical dividers with different variants. This example iterates through variants to showcase distinct styling options for horizontal content separation. ```html @for (variant of variants; track variant.label) { {{ variant.label }} } ``` -------------------------------- ### Default Light Theme Setup Source: https://www.fraktonng.com/docs/getting-started-theming-styling Configure your project to use Frakton NG's default light theme by including the main styles and the light theme CSS file. ```json { "styles": [ "node_modules/frakton-ng/assets/styles.css", "node_modules/frakton-ng/assets/themes/light.css" ] } ``` -------------------------------- ### Character Counter Example Source: https://www.fraktonng.com/docs/textarea/features Demonstrates a textarea with a live character counter, progress bar, and statistics. Useful for input fields with length restrictions. ```html
Character count: {{ characterCount() }} / {{ maxLength() }}
Words: {{ wordCount() }}
Lines: {{ lineCount() }}
Remaining: {{ remainingCharacters() }}
@if (characterCount() > warningThreshold()) {
@if (characterCount() <= maxLength()) {

⚠️ You're approaching the character limit

} @if (characterCount() > maxLength()) {

❌ Character limit exceeded by {{ characterCount() - maxLength() }} characters

}
}
``` -------------------------------- ### Ng-Bootstrap Button and Dropdown Example (Before Migration) Source: https://www.fraktonng.com/docs/getting-started-migration-guides/features Shows a typical implementation using Ng-Bootstrap's button and dropdown components, including a loading state for the button. ```typescript // Before (Ng-Bootstrap) import {NgbModule} from '@ng-bootstrap/ng-bootstrap'; @Component({ template: ` `, imports: [NgbModule] }) ``` -------------------------------- ### Raised Button Example Source: https://www.fraktonng.com/docs/button A standard raised button for primary actions. Configure text, theme, and disabled state. ```html ``` -------------------------------- ### Frakton NG Component Usage Example Source: https://www.fraktonng.com/docs/getting-started-migration-guides/features Demonstrates the usage of Frakton NG components like fkt-button, fkt-input, and fkt-select within a component's template. ```typescript @Component({ template: ` `, imports: [FktButtonComponent, FktInputComponent, FktSelectComponent] }) ``` -------------------------------- ### Skeleton Types Example Source: https://www.fraktonng.com/docs/skeleton/features Showcases different skeleton types including text, circle, rectangle, button, and image placeholders. ```html

Skeleton Types

Different skeleton types for various content placeholders.

@if (showLabels()) {

Text

Single and multi-line text placeholders

}
@if (showLabels()) {

Circle

Perfect for avatars and profile images

}
@if (showLabels()) {

Rectangle

General purpose rectangular placeholders

}
@if (showLabels()) {

Button

Button-shaped placeholders

}
``` -------------------------------- ### Basic Checkbox Example Source: https://www.fraktonng.com/docs/checkbox/features A basic FktCheckbox with label text. Clicking the checkbox or label toggles its state. This is useful for simple agreement or selection scenarios. ```html
``` -------------------------------- ### Horizontal Divider Sizes with Label Source: https://www.fraktonng.com/docs/divider/features Demonstrates different horizontal divider sizes with labels. This example iterates through variants to display various configurations. ```html @for (variant of variants; track variant.label) { {{ variant.label }} } ``` -------------------------------- ### Loading Button Example Source: https://www.fraktonng.com/docs/button A button that displays a loading state with custom text, useful for asynchronous operations. Configure text, loadingText, theme, color, loading, and disabled state. ```html ``` -------------------------------- ### Button with Icon Example Source: https://www.fraktonng.com/docs/button A button that includes an icon alongside text. Configure text, theme, color, icon, and disabled state. ```html ``` -------------------------------- ### Adding New Functionality with Frakton NG Source: https://www.fraktonng.com/docs/getting-started-migration-guides/features Demonstrates starting a migration by integrating new features using Frakton NG components alongside existing UI elements. ```typescript // Begin with new features or components @Component({ ttemplate: `
...
` }) ``` -------------------------------- ### Progress Bar Variants Source: https://www.fraktonng.com/docs/progress-bar/features Showcase different visual variants of the progress bar. This example iterates through a list of variants to apply different styles. ```html @for (variant of variants; track variant.label) { {{ variant.label }} } ``` -------------------------------- ### Vertical Divider Sizes Example Source: https://www.fraktonng.com/docs/divider/features Demonstrates vertical dividers with different sizes. This code iterates through variants to apply various size and spacing configurations for vertical separation. ```html @for (variant of variants; track variant.label) { {{ variant.label }} } ``` -------------------------------- ### Form Integration with Textarea Source: https://www.fraktonng.com/docs/textarea/features Demonstrates integrating the textarea component into a reactive form with multiple input fields. This example showcases validation, control, and submission handling. ```html

Contact Form

``` -------------------------------- ### Frakton NG Type-Safe Overlays: Usage Example Source: https://www.fraktonng.com/docs/foundation-typography Demonstrates how to use Frakton NG's overlay service to open a dialog (UserEditDialog) with full TypeScript type safety for data and callbacks. ```typescript // Use overlay with full type safety export class MyComponent { private overlay = inject(FktOverlayService) openEditDialog(user: User) { const ref = this.overlay.open({ component: UserEditDialog, data: { userId: user.id, // ✅ Auto-typed as string userName: user.name, // ✅ Auto-typed as string onSave: (userData) => { // ✅ userData auto-typed as {name: string, email: string} this.updateUser(userData); ref.close(); }, onCancel: () => ref.close() // ✅ Auto-typed as () => void } }); } } ``` -------------------------------- ### Table with Cell Alias Source: https://www.fraktonng.com/docs/table/features Example of a table utilizing cell aliases for rendering specific column data. ```HTML ``` -------------------------------- ### Pre-checked Checkbox Example Source: https://www.fraktonng.com/docs/checkbox/features A checkbox that is initialized in a checked state. The control is set up with 'true' as its default value. ```html
``` -------------------------------- ### Stroked Button Example Source: https://www.fraktonng.com/docs/button An outlined button for secondary actions. Configure text, theme, color, and disabled state. ```html ``` -------------------------------- ### Mapping Design System Tokens to Frakton Tokens Source: https://www.fraktonng.com/docs/getting-started-theming-styling Illustrates how to create a design system layer and map its tokens to Frakton's custom properties for consistent theming. ```css /* Create your design system layer */ :root { /* Your design tokens */ --ds-color-brand-100: #e0f2fe; --ds-color-brand-500: #0ea5e9; --ds-color-brand-900: #0c4a6e; /* Map to Frakton tokens */ --fkt-color-primary: var(--ds-color-brand-500); --fkt-color-primary-hover: var(--ds-color-brand-600); --fkt-color-primary-opacity-20: var(--ds-color-brand-100); } ``` -------------------------------- ### Import FktOverlayService Source: https://www.fraktonng.com/docs/overlay/features Import the FktOverlayService from the 'frakton-ng/overlay' package. ```typescript import {FktOverlayService} from "frakton-ng/overlay"; ``` -------------------------------- ### Disabled State Example Source: https://www.fraktonng.com/docs/textarea/features Shows the textarea in a disabled state, preventing user interaction. Useful for read-only or preview scenarios. ```html
Status: {{ control().disabled() ? 'Disabled' : 'Enabled' }}

Disabled textareas prevent user interaction while preserving the current value.

Common use cases include read-only views, locked fields, or conditional editing.

``` -------------------------------- ### Basic Tooltip Implementation Source: https://www.fraktonng.com/docs/tooltip/features Demonstrates the basic usage of the fktTooltip directive on buttons. Tooltips are triggered on hover and can display simple text messages. The tooltipColor input can be used to customize the tooltip's appearance. ```html
``` -------------------------------- ### Search Results Empty State Source: https://www.fraktonng.com/docs/no-results/features Configure the component for search result scenarios. This example specifically uses the 'searchConfig' input. ```html ``` -------------------------------- ### Tooltip on Interactive Elements Source: https://www.fraktonng.com/docs/tooltip/features Example of applying a tooltip to a custom interactive element. This demonstrates flexibility in attaching tooltips to non-standard components. ```HTML
?
``` -------------------------------- ### Simple Overlay Positioning Source: https://www.fraktonng.com/docs/overlay/features Demonstrates basic overlay implementation with content positioned relative to different screen edges. ```html
``` -------------------------------- ### Disabled Checkbox Example Source: https://www.fraktonng.com/docs/checkbox/features A disabled FktCheckbox. It cannot be toggled and is visually indicated with reduced opacity. Use this for options that are not currently available to the user. ```html
``` -------------------------------- ### Import FktNavigatorComponent Source: https://www.fraktonng.com/docs/navigator/features Import the FktNavigatorComponent from the 'frakton-ng/navigator' module. ```typescript import {FktNavigatorComponent} from "frakton-ng/navigator"; ``` -------------------------------- ### Mixing UI Libraries Source: https://www.fraktonng.com/docs/getting-started-migration-guides/features Demonstrates how Frakton NG components can coexist with components from Angular Material, PrimeNG, and Ng-Bootstrap without style conflicts. ```html Angular Material toolbar PrimeNG button Ng-Bootstrap button Frakton NG button ``` -------------------------------- ### Basic Tag Usage Source: https://www.fraktonng.com/docs/tag/features Demonstrates the basic usage of the fkt-tag component with text, color, and variant properties. This is a standard badge with success state and opaque styling. ```html ``` -------------------------------- ### Indeterminate Progress Bar Source: https://www.fraktonng.com/docs/progress-bar/features Display a progress bar in an indeterminate state, indicating an ongoing process without a defined end. This example iterates through variants. ```html @for (variant of variants; track variant.label) { {{ variant.label }} } ``` -------------------------------- ### Progress Bar Semantic Colors Source: https://www.fraktonng.com/docs/progress-bar/features Apply semantic colors (e.g., success, warning, danger) to the progress bar. The example iterates through predefined variants. ```html @for (variant of variants; track variant.label) { {{ variant.label }} } ``` -------------------------------- ### File Upload Empty State Source: https://www.fraktonng.com/docs/no-results/features Adapt the empty state for file management interfaces, incorporating upload capabilities. This example utilizes the 'filesConfig' input. ```html ``` -------------------------------- ### Button with Left Icon Example Source: https://www.fraktonng.com/docs/button A button with an icon positioned to the left of the text. Configure text, icon, iconPosition, theme, color, and disabled state. ```html ``` -------------------------------- ### Common Skeleton Patterns Source: https://www.fraktonng.com/docs/skeleton/features Demonstrates typical skeleton layouts for user profile cards, article previews, and product cards. ```html

Common Skeleton Patterns

Typical layouts you'll use for loading states.

User Profile Card

Article Preview

Product Card

Data Table Row

``` -------------------------------- ### Icon Only Button Example Source: https://www.fraktonng.com/docs/button A compact circular button displaying only an icon, ideal for toolbars. Configure icon, ariaLabel, theme, color, and disabled state. ```html ``` -------------------------------- ### Horizontal Divider Variants with Label Source: https://www.fraktonng.com/docs/divider/features Showcases different horizontal divider variants with labels. This example iterates through predefined variants to apply different styles. ```html @for (variant of variants; track variant.label) { {{ variant.label }} } ``` -------------------------------- ### Basic Skeleton Usage Source: https://www.fraktonng.com/docs/skeleton/features Use the fkt-skeleton component with configurable properties like width, height, type, and animation. ```html ``` -------------------------------- ### Import FktButtonsListComponent Source: https://www.fraktonng.com/docs/buttons-list/features Import the FktButtonsListComponent from the 'frakton-ng/buttons-list' module. ```typescript import {FktButtonsListComponent} from "frakton-ng/buttons-list"; ``` -------------------------------- ### Import FktInputComponent Source: https://www.fraktonng.com/docs/input Import the FktInputComponent from the frakton-ng/input library. ```typescript import {FktInputComponent} from "frakton-ng/input"; ``` -------------------------------- ### Progress Bar Sizes Source: https://www.fraktonng.com/docs/progress-bar/features Demonstrates the usage of different size options for the progress bar. Iterate through variants to apply various sizes. ```html @for (variant of variants; track variant.label) { {{ variant.label }} } ``` -------------------------------- ### Import Autocomplete Component Source: https://www.fraktonng.com/docs/autocomplete/features Import the FktAutocompleteComponent from the Frakton NG library. ```typescript import {FktAutocompleteComponent} from "frakton-ng/autocomplete"; ``` -------------------------------- ### Import FktSkeletonComponent Source: https://www.fraktonng.com/docs/skeleton/features Import the FktSkeletonComponent from the 'frakton-ng/skeleton' library. ```typescript import {FktSkeletonComponent} from "frakton-ng/skeleton"; ``` -------------------------------- ### Custom Color Progress Bar Source: https://www.fraktonng.com/docs/progress-bar/features Apply a custom hex color to the progress bar. This example iterates through variants and configures value display and indeterminate state. ```html @for (variant of variants; track variant.label) { {{ variant.label }} } ``` -------------------------------- ### Introducing Signals with Frakton NG Input Source: https://www.fraktonng.com/docs/getting-started-migration-guides/features Illustrates the gradual adoption of modern patterns by using Frakton NG's fkt-input with Angular signals and form controls. ```typescript // Gradually introduce signals export class ModernComponent { // Replace reactive forms with signal forms email = new FormControl('', [Validators.required, Validators.email]); // Use with Frakton components ttemplate = ` `; } ``` -------------------------------- ### Import FktDatePickerComponent Source: https://www.fraktonng.com/docs/date-picker/features Import the FktDatePickerComponent from the 'frakton-ng/date-picker' module. ```typescript import {FktDatePickerComponent} from "frakton-ng/date-picker"; ``` -------------------------------- ### Interactive Tooltip Element Source: https://www.fraktonng.com/docs/tooltip/features An interactive tooltip element that allows dynamic control over its text, position, and enabled state. This example uses Angular bindings for dynamic properties. ```HTML

Interactive tooltip element

``` -------------------------------- ### Tooltip Positioning - Top Source: https://www.fraktonng.com/docs/tooltip/features Examples of tooltips positioned at the top. The 'position' attribute can be set to 'top-start', 'top-center', or 'top-end'. The 'disableAutoReposition' attribute is used to prevent automatic repositioning. ```html

Top Positions

``` -------------------------------- ### Import FktCalendarNavigatorComponent Source: https://www.fraktonng.com/docs/calendar-navigator/features Import the FktCalendarNavigatorComponent from the 'frakton-ng/calendar-navigator' module. ```typescript import {FktCalendarNavigatorComponent} from "frakton-ng/calendar-navigator"; ``` -------------------------------- ### Migrating from PrimeNG Components to Frakton NG Source: https://www.fraktonng.com/docs/getting-started-migration-guides/features Illustrates a direct replacement strategy for migrating from PrimeNG components to their Frakton NG equivalents, showing the 'before' state with PrimeNG imports and template. ```typescript // Before (PrimeNG) import {ButtonModule} from 'primeng/button'; import {InputTextModule} from 'primeng/inputtext'; import {DropdownModule} from 'primeng/dropdown'; @Component({ template: ` p-button> `, imports: [ButtonModule, InputTextModule, DropdownModule] }) ```