v2.1.8
/
  • Get Started
  • Components
  • Composables
  • Typography
  • GitHub
  • Layout
  • App
  • Container
  • Error
  • SidebarLayout
  • Element
  • Advice
  • Alert
  • Avatar
  • AvatarGroup
  • Badge
  • Banner
  • Button
  • Calendar
  • Card
  • Chip
  • Collapsible
  • Countdown
  • FieldGroup
  • Kbd
  • Progress
  • Separator
  • Skeleton
  • Form
  • Checkbox
  • CheckboxGroup
  • ColorPicker
  • FileUpload
  • Form
  • FormField
  • Input
  • InputDate
  • InputMenu
  • InputNumber
  • InputTags
  • InputTime
  • PinInput
  • RadioGroup
  • Range
  • Select
  • SelectMenu
  • Switch
  • Textarea
  • Data
  • Accordion
  • DescriptionList
  • Empty
  • Table
  • TableWrapper
  • Timeline
  • User
  • Navigation
  • Breadcrumb
  • CommandPalette
  • Link
  • NavigationMenu
  • Pagination
  • Stepper
  • Tabs
  • Overlay
  • ContextMenu
  • DropdownMenu
  • Modal
  • Popover
  • Slideover
  • Toast
  • Tooltip
  • Page
  • PageCard
  • PageColumns
  • PageGrid
  • PageLinks
  • PageList
  • Dashboard
  • DashboardGroup
  • DashboardSearch
  • DashboardSearchButton
  • AI Chat
  • soonChatMessage
  • soonChatMessages
  • soonChatPalette
  • soonChatPrompt
  • soonChatPromptSubmit
  • Content
  • ContentSearch
  • ContentSearchButton
  • ContentSurround
  • ContentToc
  • Color Mode
  • ColorModeAvatar
  • ColorModeButton
  • ColorModeImage
  • ColorModeSelect
  • ColorModeSwitch
  • i18n
  • LocaleSelect
  • b24icons
  • b24jssdk
Use our Nuxt starter
v2.1.8
  • Docs
  • Components
  • Composables
  • Typography

App

Encases your app to deliver global settings and additional features.
GitHub
Nuxt UI

Usage

This component implements Reka UI ConfigProvider to provide global configuration to all components:

  • Enables all primitives to inherit global reading direction.
  • Enables changing the behavior of scroll body when setting body lock.
  • Much more controls to prevent layout shifts.

It's also using ToastProvider and TooltipProvider to provide global toasts and tooltips.

Use it as at the root of your app:

app.vue
<template>
  <B24App>
    <NuxtPage />
  </B24App>
</template>
Learn how to use the locale prop to change the locale of your app.
Learn how to use the locale prop to change the locale of your app.

API

Props

Prop Default Type
tooltip TooltipProviderProps
  • delayDuration?: number

    The duration from when the pointer enters the trigger until the tooltip gets opened. Defaults to 700.

  • skipDelayDuration?: number

    How much time a user has to enter another trigger without incurring a delay again. Defaults to 300.

  • disableHoverableContent?: boolean

    When true, trying to hover the content will result in the tooltip closing as the pointer leaves the trigger. Defaults to false.

  • disableClosingTrigger?: boolean

    When true, clicking on trigger will not close the content. Defaults to false.

  • disabled?: boolean

    When true, disable tooltip Defaults to false.

  • ignoreNonKeyboardFocus?: boolean

    Prevent the tooltip from opening if the focus did not come from the keyboard by matching against the :focus-visible selector. This is useful if you want to avoid opening it when switching browser tabs or closing a dialog. Defaults to false.

toaster null | ToasterProps
  • position?: "top-left" | "top-center" | "top-right" | "bottom-left" | "bottom-center" | "bottom-right"

    The position on the screen to display the toasts. Defaults to 'top-right'.

  • expand?: boolean

    Expand the toasts to show multiple toasts at once. Defaults to true.

  • progress?: boolean

    Whether to show the progress bar on all toasts. Defaults to true.

  • portal?: string | boolean | HTMLElement

    Render the toaster in a portal. Defaults to true.

  • max?: number

    Maximum number of toasts to display at once. Defaults to 5.

  • duration?: number

    Time in milliseconds that each toast should remain visible for. Defaults to 5000.

  • class?: any
  • b24ui?: { viewport?: ClassNameValue; base?: ClassNameValue; }
  • label?: string

    An author-localized label for each toast. Used to help screen reader users associate the interruption with a toast. Defaults to 'Notification'.

  • disableSwipe?: boolean

    Whether to disable the ability to swipe to close the toast. Defaults to false.

  • swipeThreshold?: number

    Distance in pixels that the swipe must pass before a close is triggered. Defaults to 50.

locale Locale<Messages>
  • name: string
  • code: string
  • locale: string
  • dir: Direction
  • messages: Messages
portal'body' string | false | true | HTMLElement
dir'ltr' "ltr" | "rtl"

The global reading direction of your application. This will be inherited by all primitives.

scrollBodyboolean | ScrollBodyOption

The global scroll body behavior of your application. This will be inherited by the related primitives.

  • padding?: string | number | boolean
  • margin?: string | number | boolean
nonce string

The global nonce value of your application. This will be inherited by the related primitives.

Slots

Slot Type
default{}
 

Container

A box for centering and setting a maximum width for your content.

On this page

  • Usage
  • API
    • Props
    • Slots
Releases
Published under MIT License.

Copyright © 2024-present Bitrix24