Files
Doug 097d055dbe Some more tweaks to compound for User Status. (#5708)
* Add a plain list modifier to Compound.

* Move ElementTextFieldStyle into Compound and support more styles from the Figma

- More accurately reflects our Liquid Glass updates.
- Adds support for the .raised style.

* Update Element X snapshots.
2026-06-05 15:59:34 +01:00

71 lines
1.9 KiB
Swift

//
// Copyright 2025 Element Creations Ltd.
// Copyright 2023-2025 New Vector Ltd.
//
// SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial.
// Please see LICENSE files in the repository root for full details.
//
import SwiftUI
/// A screen of components/tokens that can be navigated to.
enum Screen: Hashable, View {
/// Colour tokens
case colors
/// Gradients assembled from colour tokens
case gradients
/// Font tokens
case fonts
/// Icon tokens
case icons
/// Size tokens
case sizes
/// List styles and components
case list
/// Label styles
case labels
/// Button styles
case buttons
/// Text field styles.
case textFields
/// The `BigIcon` component.
case bigIcon
/// The `TitleAndIcon` component.
case titleAndIcon
/// The system's confirmation dialog component
case actionSheet
/// The system's alert component
case alert
/// The system's context menu component
case contextMenu
/// The system's navigation bar component
case navigationBar
/// The system's share sheet component
case shareSheet
var body: some View {
switch self {
case .colors: ColorsScreen()
case .gradients: GradientsScreen()
case .fonts: FontsScreen()
case .icons: IconsScreen()
case .list: ListScreen()
case .sizes: EmptyView()
case .labels: EmptyView()
case .buttons: ButtonsScreen()
case .textFields: TextFieldsScreen()
case .bigIcon: BigIconScreen()
case .titleAndIcon: TitleAndIconScreen()
case .actionSheet: ActionSheetScreen()
case .alert: AlertScreen()
case .contextMenu: ContextMenuScreen()
case .navigationBar: NavigationBarScreen()
case .shareSheet: ShareSheetScreen()
}
}
}