From a5756b0baacf33391b02d0208b2b009954e5b74d Mon Sep 17 00:00:00 2001 From: Teya Veselinova Date: Wed, 22 Jan 2025 15:53:03 +0200 Subject: [PATCH] fix(html): replace toolbar and tabstrip scroll buttons with spans --- packages/html/src/tabstrip/tabstrip.spec.tsx | 60 +++++++++++-- packages/html/src/toolbar/toolbar.spec.tsx | 89 ++++++++++++++++++-- 2 files changed, 135 insertions(+), 14 deletions(-) diff --git a/packages/html/src/tabstrip/tabstrip.spec.tsx b/packages/html/src/tabstrip/tabstrip.spec.tsx index aff7ac109e3..56a390ef9b5 100644 --- a/packages/html/src/tabstrip/tabstrip.spec.tsx +++ b/packages/html/src/tabstrip/tabstrip.spec.tsx @@ -1,5 +1,5 @@ -import { Button, TabStripItems, TabStripItemsWrapper } from '..'; -import { classNames, optionClassNames, Size } from '../misc'; +import { Icon, TabStripItems, TabStripItemsWrapper } from '..'; +import { classNames, FillMode, optionClassNames, Size, ThemeColor } from '../misc'; export const TABSTRIP_CLASSNAME = `k-tabstrip`; @@ -88,21 +88,69 @@ export const TabStrip = ( {scrollable && (scrollButtons === 'around' || scrollButtons === 'start') && - + + + } {scrollable && scrollButtons === 'start' && - + + + } {tabStripItems} {scrollable && scrollButtons === 'end' && - + + + } {scrollable && (scrollButtons === 'around' || scrollButtons === 'end') && - + + + } {position !== "bottom" && children} diff --git a/packages/html/src/toolbar/toolbar.spec.tsx b/packages/html/src/toolbar/toolbar.spec.tsx index 952e85c6fcc..8c7a6f2dfb1 100644 --- a/packages/html/src/toolbar/toolbar.spec.tsx +++ b/packages/html/src/toolbar/toolbar.spec.tsx @@ -5,8 +5,9 @@ import { Combobox } from '../combobox'; import { DropdownList } from '../dropdownlist'; import { MenuButton } from '../menu-button'; import SplitButton from '../split-button/split-button.spec'; -import { classNames, optionClassNames, stateClassNames, States, Size, FillMode } from '../misc'; +import { classNames, optionClassNames, stateClassNames, States, Size, FillMode, ThemeColor, Roundness } from '../misc'; import { ToolbarSeparator } from './toolbar-separator'; +import { Icon } from '../icon'; export const TOOLBAR_CLASSNAME = `k-toolbar`; @@ -204,9 +205,33 @@ export const Toolbar = ( {scrollable && scrollButtons === 'start' && <> - - - + + + + + + +
{toolbarChildren}
@@ -218,19 +243,67 @@ export const Toolbar = (
{toolbarChildren}
- - + + + + + + } {scrollable && (scrollButtons === 'around' || !scrollButtons) && <> - + + +
{toolbarChildren}
- + + + }