0
0
mirror of https://github.com/twbs/bootstrap.git synced 2024-12-01 13:24:25 +01:00

Add utility class for the user-select property (#30035)

* Add utility class for the user-select property

* Docs: Add new page for behavior utility classes - includes user select utility

* Update and rename behaviors.md to interactions.md

* Update sidebar.yml

Co-authored-by: Mark Otto <otto@github.com>
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
Co-authored-by: Martijn Cuppens <martijn.cuppens@gmail.com>
This commit is contained in:
Jens Luyten 2020-02-14 08:24:16 +01:00 committed by GitHub
parent a9263e38fd
commit 7a694396c1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 22 additions and 0 deletions

View File

@ -443,6 +443,10 @@ $utilities: map-merge(
class: font, class: font,
values: (monospace: $font-family-monospace) values: (monospace: $font-family-monospace)
), ),
"user-select": (
property: user-select,
values: all auto none
),
"rounded": ( "rounded": (
property: border-radius, property: border-radius,
class: rounded, class: rounded,

View File

@ -0,0 +1,17 @@
---
layout: docs
title: Interactions
description: Utility classes that change how users interact with contents of a website.
group: utilities
toc: false
---
## Text selection
Change the way in which the content is selected when the user interacts with it.
{{< example >}}
<p class="user-select-all">This paragraph will be entirely selected when clicked by the user.</p>
<p class="user-select-auto">This paragraph has default select behavior.</p>
<p class="user-select-none">This paragraph will not be selectable when clicked by the user.</p>
{{< /example >}}

View File

@ -80,6 +80,7 @@
- title: Display - title: Display
- title: Flex - title: Flex
- title: Float - title: Float
- title: Interactions
- title: Overflow - title: Overflow
- title: Position - title: Position
- title: Shadows - title: Shadows