LogoLogo
HomepageYouTube ChannelInstall from the AppExchange
  • Home
  • Dynamic Components
  • Flow Components
  • Experience Components
  • Projects
  • 👋Welcome
  • Getting Started
    • Product Tour
    • Quickstart Tutorial
    • Understanding The Essentials
      • Component Builder
      • Component Visibility
      • Target Page Object
      • Using Variables and Component Data
      • Publishing your Dynamic Components
      • Dynamic vs. Flow Components
    • Avonni Components App
      • Accessing the App
      • Folders
      • Templates
      • Version management
    • AppExchange Listing Page
    • Installation & Licenses Management
  • Tutorials
    • Projects
    • Components
      • Calendar
        • How to Create Events Quickly by Dragging
        • How to Add an Edit Action to Calendar Events
        • How to Add a New Event Button to the Calendar Header
        • How to Customize the Right-Click Menu
        • How to Reschedule Events with Drag and Drop
      • Columns
        • Creating a Responsive 3-Column Layout
      • Data Table
        • How to customize Data Table style
        • How to make a field editable
        • How to add clickable buttons
        • How to color-code badges
        • How to export data
        • How to configure search
        • How to set columns visibility
      • Kanban
        • Saving Changes on Drag-and-Drop
      • List
      • Metric
      • Record Detail
        • Saving Changes
    • Interactions
      • How to create an interaction to navigate to an object page
      • How to create an interaction to navigate to a record page
      • How to Pass Multiple Selected Records from a Dynamic Component to a Screen Flow
    • Reactive Components
      • Reactive Map and Data Table
      • Master-Detail Relationship with Data Tables
      • Vertical Tabs with Reactive Data Table
    • Style
      • How do you add space or a break between sections or fields?
    • Tips and Tricks
      • Using the Dynamic Component component
  • Component Builder
    • Overview
    • Configuring Components
      • Properties
      • Fields
      • Style
    • Data & Interactions
      • Data Sources
        • Manual
        • Picklist
      • Resources
        • Constant
        • Formula
        • Nested Queries
        • Query
        • Variable
      • Interactions
        • CRUD from Record Variable
        • Download
        • Execute Flow
        • Navigate
        • On Load
        • Open Alert Modal
        • Open Confirm
        • Open Dynamic Component Dialog
        • Open Dynamic Component Panel
        • Open Flow Panel
        • Open Flow Dialog
        • Show Toast
    • Advanced Topics
      • Undo / Redo
      • Copy and Paste
      • Keyboard Shortcut
  • Components
    • Explore All Components
    • Accordion
    • Alert
    • Audio Player
    • Avatar
    • Avatar Group
    • Badge
    • Barcode
    • Blockquote
    • Button
    • Button Group
    • Button Icon
    • Button Menu
    • Button Stateful
    • Calendar
    • Camera 🆕
    • Card
    • Carousel
    • Chart
    • Checkbox
    • Checkbox Button
    • Chip Container
    • Color Picker
    • Columns
    • Combobox
    • Container
    • Counter
    • Data LWC Container
    • Data Table
    • Date Picker
    • Date
    • Date Range
    • Dual Listbox
    • Dynamic Component
    • Formatted Address
    • Formatted Name
    • Formatted Value
    • Header
    • Icon
    • Icon Picker
    • Illustration
    • Image
    • Input Color
    • Input Date
    • Input Pen (Signature)
    • Input Text
    • Kanban
    • List
    • LWC Container
    • Map
    • Media Object
    • Metric
    • PDF Viewer
    • Pivot Table
    • Progress Bar
    • Progress Circle
    • Progress Indicator
    • Rating
    • Record Detail
    • Relationship Graph
    • Scope Notification
    • Section
    • Separator
    • Slider
    • Status
    • Tabbed Container
    • Tabs
    • Text
    • Text Area
    • Timeline
    • Toggle
    • Tree
    • Vertical Visual Picker
    • Video Player
    • Visual Picker
    • Visual Picker Link
  • Help
    • Contact Support
    • Security
    • Performance Guide
    • Deployment Process
    • Release Notes
    • Report Bugs
Powered by GitBook
LogoLogo

Company

  • About Us
  • Pricing

Policies

  • Privacy Policy
  • Terms of Service
On this page
  • Overview
  • The Style Tab
  • Component-Specific Styling (Default Style)
  • Example
  • Creating and Using Reusable Custom Styles
  • Example: Reusable "RedMetric" Style
  • Important Considerations
  • Tutorials
  • In Summary

Was this helpful?

  1. Component Builder
  2. Configuring Components

Style

Last updated 1 month ago

Was this helpful?

Avonni Dynamic Components offer extensive styling options, allowing you to customize the appearance of your components to match your brand and create a polished user experience. The Style Panel is your central hub for managing these styles.

Overview

Every Avonni component has a set of default styles defining its basic appearance. You can customize these styles in two ways:

  • Component-Specific Styling (Default Style Selector): Modify the styles of a single, specific component instance. These changes will only affect that one component.

  • Reusable Custom Styles: Create named custom style selectors that define a set of style attributes. You can then apply these custom styles to multiple components, ensuring consistency and making it easy to update styles globally.


The Style Tab

The Style tab is on the right side of the Component Builder when you select an Avonni Component. It contains:

  • Style Attributes: A list of attributes you can customize to change the component's appearance (e.g., colors, fonts, spacing).

  • Style Selector: A menu where you can create and apply custom CSS classes to the component.


Component-Specific Styling (Default Style)

When adding a component to the canvas, it uses the "Default" style. If you modify style attributes (e.g., color, font size, padding) while the "Default" style is selected, those changes will only affect that specific instance of the component.

Example

  1. You add a Button component.

  2. You select the Button component.

  3. You see "Default" is selected in the Style Panel.

  4. You change the Button's background color to red in the Properties Panel.

  5. Only that specific Button will have a red background. Other Button components will retain their default appearance.

This is useful for one-off customizations.


Creating and Using Reusable Custom Styles

To create reusable styles that you can apply to multiple components:

  1. Select a Component: Select any component on the canvas. It doesn't matter which component you select initially.

  2. Open the Style Panel: Go to the Style Panel.

  3. To create a new style

    1. Go to the Style Selector: This is in the Style tab of the Component Builder.

    2. Name your style: Give it a clear name that describes its purpose (e.g., RedMetric, PrimaryButton).

    3. Create the style: Click the + Create "[styleName]" button to generate the custom CSS class.

  4. Customize the Style Attributes

    • With your new custom style selected (highlighted) in the Style Panel, use the Properties Panel to modify the style attributes of the currently selected component. For example, you might change the background color, font size, border, padding, etc.

    • Important: The changes you make here are saved to the custom style, not just to the individual component you initially selected.

  5. Apply the Style to Other Components

    • Select another component on the canvas (of the same type as the component you used to create the style – you can apply a Button style to another Button, but not to a Data Table).

    • In the Style Panel, you'll see your custom style listed.

    • Click on the Style attribute in the Properties Panel

    • Select your custom style to apply it to the selected component.

  6. See applied Styles

    • You can also visualize components that uses styles from the Style Panel directly.

Now, all components you've applied that custom style will share the same appearance. If you edit the custom style later, all components using that style will automatically update.


Example: Reusable "RedMetric" Style

  1. Add a Metric component to your canvas.

  2. Open the Style Panel.

  3. Click the "+" (or "New Style") button to create a new style.

  4. Name the style RedMetric.

  5. With the RedMetric style selected in the Style Panel, select the Metric component.

  6. Change the Metric component Background color to red (using the Properties Panel).

  7. Add another Metric component to your Canvas.

  8. Click on this component, then select the Style Attribute.

  9. Select your custom RedMetric style.

Now, both Metric components will have a red background. If you later change the background color defined in the RedMetric style (in the Style Panel), both Metric components will update automatically.


Important Considerations

  • Style Scope: Currently, custom styles are scoped to the individual Dynamic Component where they are created. They are not shared between different Dynamic Components. However, we plan to introduce cross-component style sharing in an upcoming release.

  • Component Type Compatibility: You can only apply a custom style to components of the same type as the component you used to create the style. You can't apply a Button style to a Data Table.

  • Overriding Styles: You can override a custom style on a specific component by making further changes while selecting the "Default" style. This creates a component-specific override.

  • Deleting Styles: You can delete custom styles in the Style Panel. Be careful, as this will affect all components using that style.

  • Style Naming: Use a straightforward naming convention to organize your custom styles so they are easily recognized.


Tutorials


In Summary

Custom styles in Avonni Components can be easily added and applied to other component of the same type. You can also easily visualize component that uses your Styles

How do you add space or a break between sections or fields?
Location of the Style Panel