This commit is contained in:
2026-09-15 10:26:34 +08:00
commit ecf36afa56
10493 changed files with 1404888 additions and 0 deletions
+948
View File
@@ -0,0 +1,948 @@
# Magento UI library
The Magento UI library is a flexible modular Magento frontend library that is designed to assist Magento theme developers. It employs a set of mixins for base elements to ease frontend theme development and customization. The Magento UI library offers the following characteristics for those who develop or customize Magento themes. It is:
* Built on LESS preprocessor
* Focused on web standards
* Customizable
* Easy to maintain
* Responsive
* Accessible
The library provides the ability to customize all of the following user interface elements:
* actions-toolbar
* breadcrumbs
* buttons
* components
* drop-downs
* forms
* icons
* layout
* loaders
* messages
* pagination
* popups
* ratings
* resets
* responsive
* sections - tabs and accordions
* tables
* tooltips
* typography
* utilities
* list of theme variables
# Magento UI library file structure
Magento UI library is located under `/lib/web/` folder. It and employs:
* `css/` folder where the library files are placed
* `fonts/` folder where default and icon fonts are placed
* `images/` folder where default images are placed
* `jquery/` folder where jQuery and jQuery widgets are placed
### Magento UI library structure
```css
/lib/web/
├── css/
│ ├── docs/ (Library documentation)
│ │ ├── source/
│ │ │ ├── _actions-toolbar.less
│ │ │ ├── _breadcrumbs.less
│ │ │ ├── _buttons.less
│ │ │ ├── _dropdowns.less
│ │ │ ├── _forms.less
│ │ │ ├── _icons.less
│ │ │ ├── _layout.less
│ │ │ ├── _lib.less
│ │ │ ├── _loaders.less
│ │ │ ├── _messages.less
│ │ │ ├── _pages.less
│ │ │ ├── _popups.less
│ │ │ ├── _rating.less
│ │ │ ├── _resets.less
│ │ │ ├── _responsive.less
│ │ │ ├── _sections.less
│ │ │ ├── _tables.less
│ │ │ ├── _tooltips.less
│ │ │ ├── _typography.less
│ │ │ ├── _utilities.less
│ │ │ ├── _variables.less
│ │ │ ├── _components.less
│ │ │ ├── docs.less
│ │ │ └── README.md
│ │ ├─── extends.html
│ │ ├─── actions-toolbar.html
│ │ ├─── breadcrumbs.html
│ │ ├─── buttons.html
│ │ ├─── components.html
│ │ ├─── docs.css
│ │ ├─── docs.html
│ │ ├─── dropdowns.html
│ │ ├─── forms.html
│ │ ├─── icons.html
│ │ ├─── index.html
│ │ ├─── layout.html
│ │ ├─── lib.html
│ │ ├─── loaders.html
│ │ ├─── messages.html
│ │ ├─── pages.html
│ │ ├─── popups.html
│ │ ├─── rating.html
│ │ ├─── resets.html
│ │ ├─── responsive.html
│ │ ├─── sections.html
│ │ ├─── tables.html
│ │ ├─── tooltips.html
│ │ ├─── typography.html
│ │ ├─── utilities.html
│ │ └─── variables.html
│ └── source/
│ ├── components/ (Reusable components files)
│ │ └── _modals.less
│ ├── lib/ (Library source files)
│ │ └── variables/ (Decoupled variables)
│ │ └── ...
│ │ ├── _extends.less
│ │ ├── _actions-toolbar.less
│ │ ├── _breadcrumbs.less
│ │ ├── _buttons.less
│ │ ├── _dropdowns.less
│ │ ├── _forms.less
│ │ ├── _icons.less
│ │ ├── _layout.less
│ │ ├── _lib.less
│ │ ├── _loaders.less
│ │ ├── _messages.less
│ │ ├── _navigation.less
│ │ ├── _pages.less
│ │ ├── _popups.less
│ │ ├── _rating.less
│ │ ├── _resets.less
│ │ ├── _responsive.less
│ │ ├── _sections.less
│ │ ├── _tables.less
│ │ ├── _tooltips.less
│ │ ├── _typography.less
│ │ ├── _utilities.less
│ │ └── _variables.less
│ ├── _extend.less
│ └── _theme.less
├── fonts/
│ └── Blank-Theme-Icons/ (Library custom icons font)
├── images/
│ └── blank-theme-icons.png (Library icons sprite)
└── jquery/ (Library javascript files)
```
 
# Magento UI library naming convention
Magento UI library employs a variables and mixins naming convention whereby names of variables and mixins describe their purpose or functions they perform.
A variable or a mixins name may only contain lowercase alphanumeric characters, "-" and "_" characters. A variable name must start with "@" character.
If a variable or mixins name consists of more than one word, they must be concatenated with one hyphen character.
# Less variables naming
A *.less file variable can contain lowercase letters, numbers, special characters: "@", "-" and "_". It must start with "@" character and consist of words concatenated with one hyphen. It should not contain capital letters. A variable name should describe its purpose.
A variable name should be formed according to the following rule:
`'@' + 'object' + '-' + 'property' + '-' + 'state' = @object-property-state`
If it is a private variable (is used only in a mixin), it must start with "_" character after "@":
`'@' + '_' + 'object' + '-' + 'property' + '-' + 'state' = @_object-property-state`
#### Examples:
##### Acceptable:
```css
@link-color-hover;
@color-primary;
@color-2;
```
Private variables:
```css
@_padding-left;
@_font-size;
```
##### Unacceptable:
```css
@Link-Color-Hover;
@colorPrimary;
@color--primary;
@paddingleft;
@__font-size;
```
 
# Less mixins naming
A less mixin name can contain lowercase letters, numbers, "-" and "_" characters. It should not contain capital letters.
A mixin name can consist of one or several words, concatenated with one hyphen. If the mixin is private, its name must start with the "_" character. Mixin should be named after property or action it describes.
#### Examples:
##### Acceptable:
```css
.mixin-name() {}
.transition() {}
.mixin() {}
._button-gradient() {}
```
##### Unacceptable:
```css
.mixinName() {}
.__transition() {}
.MiXiN() {}
._button--gradient() {}
```
 
# Less Code Standards
## General rules
### Indentation
Please verified that you use spaces instead tabs:
* Tab size: 4 spaces
* Indent size: 4 spaces
* Continuation indent: 4 spaces
```css
.nav {
.nav-item {
...
}
}
```
### Format
#### Braces
Add space before opening brace and line break after. And line break before closing brace.
##### Not recommended:
```css
.nav{color: @nav__color;}
```
##### Recommended:
```css
.nav {
color: @nav__color;
}
```
#### Selector delimiters
Add line break after each selector delimiter. Delimeter shouldn't have spaces before and after.
##### Not recommended:
```css
.nav, .bar {
color: @color__base;
}
```
##### Recommended:
```css
.nav,
.bar {
color: @color__base;
}
```
#### Quotes
Use single quotes
##### Not recommended:
```css
.nav {
content: "lorem ipsum";
}
```
##### Recommended:
```css
.nav {
content: 'lorem ipsum';
}
```
#### Combinator indents
Use spaces before and after combinators
##### Not recommended:
```css
.nav+.bar {
color: @bar__color;
}
.nav +.bar {
color: @bar__color;
}
.nav+ .bar {
color: @bar__color;
}
```
##### Recommended:
```css
.nav + .bar {
color: @bar__color;
}
```
#### Properties line break
Use line break for each property declaration
##### Not recommended:
```css
.nav {
color: @nav__color; background-color: @nav__background-color;
}
```
##### Recommended:
```css
.nav {
background-color: @nav__background-color;
color: @nav__color;
}
```
#### Properties colon indents
Use no space before property colon, and space after
##### Not recommended:
```css
.nav {
color : @nav__color;
}
.bar {
color:@bar__color;
}
.item {
color :@item__color;
}
```
##### Recommended:
```css
.nav {
color: @nav__color;
}
```
#### End of file
Each less file should be finished with new line
#### End of the selector
Each selector should be finished with new line
##### Not recommended:
```css
.nav {
background-color: @nav__background-color;
}
.bar {
background-color: @bar__background-color;
}
```
##### Recommended:
```css
.nav {
background-color: @nav__background-color;
}
.bar {
background-color: @bar__background-color;
}
```
#### End of the property line
Each property should be finished with semicolon
##### Not recommended:
```css
.nav {
background-color: @nav__background-color
}
```
##### Recommended:
```css
.nav {
background-color: @nav__background-color;
}
```
#### !Important property
Basically avoid use this property at all, but if you really really need it use the following format:
##### Not recommended:
```css
.jquery-ui-calendar-item {
background-color: @nav__background-color!important;
}
```
##### Recommended:
```css
.jquery-ui-calendar-item {
background-color: @nav__background-color !important;
}
```
### Comments
Please follow the next format of comments
```css
//
// First level comment
// _____________________________________________
.nav {
background-color: @nav__background-color;
}
//
// Second level comment
// ---------------------------------------------
.nav {
background-color: @nav__background-color;
}
// Comment
.nav {
// New line comment
background-color: @nav__background-color; // ToDo UI: todo inline comment
color: @nav__color; // inline comment
}
```
### Selectors
#### Types
According to browser support standards the oldest browser that we support is IE9+, it means that you can feel free to use almost all CSS3 selectors: descendants, attributes, pseudo classes, structural, pseudo elements, etc.
Exeption: Please avoid to use id selector.
##### Not recommended:
```css
#foo {
...
}
```
##### Recommended:
```css
.nav {
...
}
.nav + bar {
...
}
.nav:not(.bar) {
...
}
```
### Naming
#### Standard classes
All classes should be written in lowercase, starts with letter (exept helpers), words in classes should be separated with dash (minus sign '-')
##### Not recommended:
```css
.navBar {
...
}
```
##### Not recommended: underscore separation
```css
.nav_bar {
...
}
```
##### Recommended:
```css
.nav-bar {
...
}
```
#### Helper classes
Helper classes should be written in lowercase, starts with underscore ("_")
##### Example:
```css
._active {
...
}
```
### Size
Use class names that are as short as possible but as long as necessary.
Try to convey what class is about while being as brief as possible.
Using class names this way contributes to acceptable levels of understandability and code efficiency.
##### Not recommended: too long
```css
.navigation-panel-in-footer {
...
}
```
##### Not recommended: too short
```css
.nvpf {
...
}
```
##### Recommended:
```css
.nav-bar {
...
}
```
### Writing
Write selector name together in single line, don't use concatenation
##### Not recommended:
```css
.product {
...
&-list {
...
&-item {
...
}
}
}
```
##### Recommended:
```css
.product-list-item {
...
}
```
### Meaning
**Use meaningful or generic class names.**
Instead of presentational or cryptic names, always use class names that reflect the purpose of the element in question, or that are otherwise generic.
Names that are specific and reflect the purpose of the element should be preferred as these are most understandable and the least likely to change.
Generic names are simply a fallback for elements that have no particular or no meaning different from their siblings. They are typically needed as “helpers.”
Using functional or generic names reduces the probability of unnecessary document or template changes.
##### Not recommended:
```css
.foo-1901 {
...
}
```
##### Not recommended: presentational
```css
.button-green {
...
}
.clear {
...
}
```
##### Recommended: specific
```css
.category {
...
}
.category-title {
...
}
```
### Type selectors
**Avoid qualifying class names with type selectors.**
Unless necessary (for example with helper classes), do not use element names in conjunction with IDs or classes.
Avoiding unnecessary ancestor selectors is useful for performance reasons.
##### Not recommended:
```css
div.error {
...
}
```
##### Recommended:
```css
.error {
...
}
```
Use type selectors in lowercase
##### Not recommended:
```css
.nav > LI {
...
}
```
##### Recommended:
```css
.nav > li {
...
}
```
### Nesting
Be careful with selectors nesting. In general try to use 3 nested levels as max.
Exception are pseudo elements and states
##### Not recommended:
```css
.footer {
...
.nav {
...
.nav-list {
...
.nav-list-item {
...
}
}
}
}
```
##### Recommended:
```css
.footer {
...
.nav {
...
}
.nav-list {
...
}
.nav-list-item {
...
}
}
```
## Properties
### Sort
Sort all properties alphabetical. Mixins, variables etc. should go first
##### Not recommended:
```css
.nav {
color: @nav__color;
text-align: center;
background-color: @nav__background-color;
}
```
##### Recommended:
```css
.nav {
background-color: @nav__background-color;
color: @nav__color;
text-align: center;
}
```
### Shorthand
Use shortland properties where possible.
CSS offers a variety of shorthand properties (like font) that should be used whenever possible, even in cases where only one value is explicitly set.
Using shorthand properties is useful for code efficiency and understandability.
##### Not recommended:
```css
border-top-style: none;
padding-bottom: 2rem;
padding-left: 1rem;
padding-right: 1rem;
padding-top: 0;
```
##### Recommended:
```css
border-top: 0;
padding: 0 1em 2em;
```
### 0 and units
Omit unit specification after "0" values.
##### Not recommended:
```css
border-width: 0px;
margin: 0rem;
```
##### Recommended:
```css
border-width: 0;
margin: 0;
```
### Floating values
Omit leading "0"s in values, use dot instead
##### Not recommended:
```css
margin-left: 0.5rem;
```
##### Recommended:
```css
margin-left: .5rem;
```
### Hexadecimal notation
* Use lowercase only
* Use 3 character hexadecimal notation where possible.
* For color values that permit it, 3 character hexadecimal notation is shorter and more succinct.
* Also please avoid hex color in properties, use only variables instead.
##### Not recommended:
```css
color: #ff0000;
@nav__color: #FAFAFA;
@nav-item__color: red;
```
##### Recommended:
```css
@nav__color: #fafafa;
@nav-item__color: #f00;
...
color: @nav-item__color;
```
## Variables
### Location
#### Local variables
If variables are local and used only in module scope it should be located in module file, on the top of the file with general comment
Example **_module.less**:
```css
...
//
// Variables
// _____________________________________________
// Colors
@btn__color: @color-brownie;
@btn-primary__color: @color-white;
@btn-secondary__color: @color-white;
...
```
#### Theme variables
If variables are common for couple modules it should be located in **_theme.less** file
#### Global variables
If variables are common for couple themes it should be located in global lib in **_variables.less** file
### Naming
All variables should be written in lowercase.
#### Value variables
##### General model is:
```css
@property-name
```
##### Examples:
```css
@primary__color: @color-phoenix;
@indent__base: 2rem;
@border-radius-round: 100%;
```
#### Parameter variables
##### General model is:
```css
@component-element__state__property__modifier
```
Please mention that component can be not only element name, it also can be primary, secondary, tertiary
Base is a modifier
##### Examples:
```css
@color-orange: '';
@link__hover__color: '';
@nav-element__background-color: '';
@secondary__color: '';
@side-nav__indent__s: '';
@side-nav-el__background-color: '';
@side-nav-el__active__background-color: '';
@side-nav-el__active-focus__background-color: '';
@side-nav-el__active-focus__font-size__xl: '';
@text__color__base: '';
```
## Mixins
### Location
Theme mixins (except extends) should be saved in **source/utilities** folder
Extends that used in more than one theme should be saved in lib **lib/source/utilities.less** (will be separated into utilities folder)
### Naming
In name creation you can follow the same rules as for the creation of class names.
For mixins grouping use prefix__
##### Example:
```css
.extend__clearfix (...) {
...
}
.vendor-prefix__flex-direction (...) {
...
}
```
## Extends
### Location
Local extends that used only in one file, should be written in this **local file**.
Extends that used in more than two files should be saved in theme **source/_extend.less**
Extends that used in more than one theme should be saved in lib **lib/source/_abstract.less** (will be renamed to _extend.less)
### Naming
Extend class names should have prefix **.abs-** (from abstract)
@@ -0,0 +1,388 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
// # Actions toolbar
// Actions toolbar is a set of actions on a page, form and so on that includes primary and/or secondary actions.
// To customize action toolbar <code>.lib-actions-toolbar()</code> mixin is used.
// To implement the Actions toolbar use the following markup
//
// **Sample of using a button + link**
// ``` html
// <div class="actions-toolbar">
// <div class="primary">
// <button type="submit" class="action submit" title="Submit"><span>Submit</span></button>
// </div>
// <div class="secondary">
// <a class="action back" href="#"><span>Back</span></a>
// </div>
// </div>
// ```
//
// **Sample of using a button + button**
// ``` html
// <div class="example-actions-toolbar-1">
// <div class="primary">
// <button type="submit" class="action submit" title="Submit"><span>Redeem Gift Card</span></button>
// </div>
// <div class="secondary">
// <button class="action check" type="button" value="Check status and balance">
// <span>Check status and balance</span>
// </button>
// </div>
// </div>
// ```
.actions-toolbar {
.lib-actions-toolbar();
}
.example-actions-toolbar-1 {
.lib-actions-toolbar();
}
// # Actions toolbar mixin variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Global variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_actions-toolbar-actions-position</th>
// <td>@actions-toolbar-actions__position</td>
// <td class="vars_value">justify</td>
// <td class="vars_value">justify | left | right | center</td>
// <td>Position for actions in Actions toolbar</td>
// </tr>
// <tr>
// <th>@_actions-toolbar-actions-reverse</th>
// <td>@actions-toolbar-actions__reverse</td>
// <td class="vars_value">false</td>
// <td class="vars_value">true | false</td>
// <td>Reverse primary and secondary blocks position in Actions toolbar</td>
// </tr>
// <tr>
// <th>@_actions-toolbar-margin</th>
// <td>@actions-toolbar__margin</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Margins of the Actions toolbar</td>
// </tr>
// <tr>
// <th>@_actions-toolbar-padding</th>
// <td>@actions-toolbar__padding</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Padding of the Actions toolbar</td>
// </tr>
// <tr>
// <th>@_actions-toolbar-actions-margin</th>
// <td>@actions-toolbar-actions__margin</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Margins of all .actions in the Actions toolbar</td>
// </tr>
// <tr>
// <th>@_actions-toolbar-primary-actions-margin</th>
// <td>@actions-toolbar-actions-primary__margin</td>
// <td class="vars_value">0 @indent__xs 0 0</td>
// <td class="vars_value">'' | false | value</td>
// <td>Margins of primary .actions in the Actions toolbar</td>
// </tr>
// <tr>
// <th>@_actions-toolbar-secondary-actions-margin</th>
// <td>@actions-toolbar-actions-secondary__margin</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Margins of secondary .actions in the Actions toolbar</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_actions-toolbar-actions-links-margin-top</th>
// <td>@actions-toolbar-actions-links__margin-top</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Margin-top for links with class .action in the Actions toolbar</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_actions-toolbar-primary-actions-links-margin-top</th>
// <td>@actions-toolbar-actions-links-primary__margin-top</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Margin-top for primary links with class .action in the Actions toolbar</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_actions-toolbar-secondary-actions-links-margin-top</th>
// <td>@actions-toolbar-actions-secondary__margin</td>
// <td class="vars_value">6px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Margin-top for secondary links with class .action in the Actions toolbar</td>
// </tr>
// </table>
// </pre>
//
// # Actions toolbar alignment
//
// <code>@_actions-toolbar-actions-position</code> variable controls aligning actions toolbar elements. It can be set to:
// ```css
// justify | left | right | center
// ```
//
// **Justify:**
// ```css
// @_actions-toolbar-actions-position: justify
// ```
// ``` html
// <div class="example-actions-toolbar-2">
// <div class="primary">
// <button type="submit" class="action submit" title="Submit"><span>Submit</span></button>
// </div>
// <div class="secondary">
// <a class="action back" href="#"><span>Back</span></a>
// </div>
// </div>
// ```
//
// **Align toolbar elements left:**
// ```css
// @_actions-toolbar-actions-position: left
// ```
// ``` html
// <div class="example-actions-toolbar-3">
// <div class="primary">
// <button type="submit" class="action submit" title="Submit"><span>Submit</span></button>
// </div>
// <div class="secondary">
// <a class="action back" href="#"><span>Back</span></a>
// </div>
// </div>
// ```
//
// **Align toolbar elements right:**
// ```css
// @_actions-toolbar-actions-position: right
// ```
// ``` html
// <div class="example-actions-toolbar-4">
// <div class="primary">
// <button type="submit" class="action submit" title="Submit"><span>Submit</span></button>
// </div>
// <div class="secondary">
// <a class="action back" href="#"><span>Back</span></a>
// </div>
// </div>
// ```
//
// **Center:**
// ```css
// @_actions-toolbar-actions-position: center
// ```
// ``` html
// <div class="example-actions-toolbar-5">
// <div class="primary">
// <button type="submit" class="action submit" title="Submit"><span>Submit</span></button>
// </div>
// <div class="secondary">
// <a class="action back" href="#"><span>Back</span></a>
// </div>
// </div>
// ```
.example-actions-toolbar-2 {
.lib-actions-toolbar(
@_actions-toolbar-actions-position: justify
);
}
.example-actions-toolbar-3 {
.lib-actions-toolbar(
@_actions-toolbar-actions-position: left
);
}
.example-actions-toolbar-4 {
.lib-actions-toolbar(
@_actions-toolbar-actions-position: right
);
}
.example-actions-toolbar-5 {
.lib-actions-toolbar(
@_actions-toolbar-actions-position: center
);
}
// # Reverse primary and secondary blocks
//
// <code>@_actions-toolbar-actions-reverse</code> variable controls reversing of primary and secondary blocks.
//
// If it is set to <code>false</code>, the order of blocks in action toolbar is **default**.
//
// If it is set to <code>true</code>, the order of blocks in action toolbar is **reversed**.
//
// **Justify toolbar elements and reverse them:**
// ```css
// @_actions-toolbar-actions-position: justify,
// @_actions-toolbar-actions-reverse: true
// ```
// ``` html
// <div class="example-actions-toolbar-6">
// <div class="primary">
// <button type="submit" class="action submit" title="Submit"><span>Submit</span></button>
// </div>
// <div class="secondary">
// <a class="action back" href="#"><span>Back</span></a>
// </div>
// </div>
// ```
//
// **Align toolbar elements to the left and reverse them:**
// ```css
// @_actions-toolbar-actions-position: left,
// @_actions-toolbar-actions-reverse: true
// ```
// ``` html
// <div class="example-actions-toolbar-7">
// <div class="primary">
// <button type="submit" class="action submit" title="Submit"><span>Submit</span></button>
// </div>
// <div class="secondary">
// <a class="action back" href="#"><span>Back</span></a>
// </div>
// </div>
// ```
//
// **Align toolbar elements to the right and reverse them:**
// ```css
// @_actions-toolbar-actions-position: right,
// @_actions-toolbar-actions-reverse: true
// ```
// ``` html
// <div class="example-actions-toolbar-8">
// <div class="primary">
// <button type="submit" class="action submit" title="Submit"><span>Submit</span></button>
// </div>
// <div class="secondary">
// <a class="action back" href="#"><span>Back</span></a>
// </div>
// </div>
// ```
.example-actions-toolbar-6 {
.lib-actions-toolbar(
@_actions-toolbar-actions-position: justify,
@_actions-toolbar-actions-reverse: true
);
}
.example-actions-toolbar-7 {
.lib-actions-toolbar(
@_actions-toolbar-actions-position: left,
@_actions-toolbar-actions-reverse: true
);
}
.example-actions-toolbar-8 {
.lib-actions-toolbar(
@_actions-toolbar-actions-position: right,
@_actions-toolbar-actions-reverse: true
);
}
// # Actions toolbar indents customizations
//
// <code>@_actions-toolbar-margin</code> variable controls margins of the actions toolbar wrapper.
//
// <code>@_actions-toolbar-padding</code> variable controls padding of the actions toolbar wrapper.
//
// ``` html
// <div class="example-actions-toolbar-9">
// <div class="primary">
// <button type="submit" class="action submit" title="Submit"><span>Submit</span></button>
// </div>
// <div class="secondary">
// <a class="action back" href="#"><span>Back</span></a>
// </div>
// </div>
// ```
//
// <code>@_actions-toolbar-primary-actions-margin</code> variable controls margins of the primary action elements.
//
// ``` html
// <div class=" example-actions-toolbar-10">
// <div class="primary">
// <button type="submit" class="action submit" title="Submit"><span>Submit</span></button>
// <button type="submit" class="action submit2" title="Submit2"><span>Submit2</span></button>
// </div>
// <div class="secondary">
// <a href="#" class="action towishlist"><span>Add to Wish List</span></a>
// <a href="#" class="action tocompare"><span>Add to Compare</span></a>
// </div>
// </div>
// ```
//
// <code>@_actions-toolbar-secondary-actions-margin</code> variable controls margins of the secondary action elements.
//
// ``` html
// <div class="example-actions-toolbar-11">
// <div class="primary">
// <button type="submit" class="action submit" title="Submit"><span>Submit</span></button>
// <button type="submit" class="action submit2" title="Submit2"><span>Submit2</span></button>
// </div>
// <div class="secondary">
// <a href="#" class="action towishlist"><span>Add to Wish List</span></a>
// <a href="#" class="action tocompare"><span>Add to Compare</span></a>
// </div>
// </div>
// ```
.example-actions-toolbar-9 {
.lib-actions-toolbar(
@_actions-toolbar-margin: 10px,
@_actions-toolbar-padding: 10px
);
}
.example-actions-toolbar-10 {
.lib-actions-toolbar(
@_actions-toolbar-actions-position: left,
@_actions-toolbar-primary-actions-margin: 0 50px 0 0
);
}
.example-actions-toolbar-11 {
.lib-actions-toolbar(
@_actions-toolbar-actions-position: left,
@_actions-toolbar-secondary-actions-margin: 0 50px 0 0
);
}
// # Responsive actions toolbar
//
// To set up responsive action toolbar, all floats of its elements should be cleared. To do this <code>.lib-actions-toolbar-clear-floats()</code> mixin is used.
//
// ``` html
// <div class="example-actions-toolbar-12">
// <div class="primary">
// <button type="submit" class="action submit" title="Submit"><span>Submit</span></button>
// </div>
// <div class="secondary">
// <a href="#" class="action towishlist"><span>Add to Wish List</span></a>
// </div>
// </div>
// ```
.example-actions-toolbar-12 {
.lib-actions-toolbar();
}
@media only screen and (max-width: @screen__m) {
.example-actions-toolbar-12 {
.lib-actions-toolbar-clear-floats();
}
}
+537
View File
@@ -0,0 +1,537 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
// # Breadcrumbs
// Breadcrumbs or breadcrumb trail is a navigation aid used in user interfaces. It allows users to keep track of their location within programs, websites or documents.
//
// Breadcrumbs layout with links can be separated by any symbol, for example <code>></code> symbol.
//
// The following markup corresponds to the accessibility demands:
// ```html
// <div class="example-breadcrumbs-1">
// <span class="label" id="breadcrumb-label">You are here:</span>
// <ul class="items" aria-labelledby="breadcrumb-label">
// <li class="item home">
// <a title="Go to Home Page" href="#">Home</a>
// </li>
// <li class="item category1">
// <a title="Category" href="#">Category</a>
// </li>
// <li class="item category2">
// <a title="Category" href="#">Subcategory</a>
// </li>
// <li class="item category3">
// <strong>Products</strong>
// </li>
// </ul>
// </div>
// ```
.example-breadcrumbs-1 {
.lib-breadcrumbs();
}
// # Breadcrumbs variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Global variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_breadcrumbs-font-size</th>
// <td>@breadcrumbs__font-size</td>
// <td class="vars_value">@font-size__s</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs font size</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-display</th>
// <td>@breadcrumbs__display</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | inline | block | inline-block</td>
// <td>Breadcrumbs links display property</td>
// </tr>
// <tr>
// <th>@_breadcrumbs__container-margin</th>
// <td>@breadcrumbs__container-margin</td>
// <td class="vars_value"> 0 0 @indent__base</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs items padding</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-padding</th>
// <td>@breadcrumbs__padding</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs items padding</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Breadcrumbs - separator symbol</th>
// </tr>
// <tr>
// <th>@_breadcrumbs-separator-symbol</th>
// <td>@breadcrumbs-separator__symbol</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | any symbol</td>
// <td>Breadcrumbs separating symbol</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-separator-color</th>
// <td>@breadcrumbs-separator__color</td>
// <td class="vars_value" nowrap="nowrap">@breadcrumbs-current__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs separating symbol color</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-icon-use</th>
// <td>@breadcrumbs-icon__use</td>
// <td class="vars_value">true</td>
// <td class="vars_value">true | false</td>
// <td>Breadcrumbs separating symbol is an icon</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-icon-font-content</th>
// <td>@breadcrumbs-icon__font-content</td>
// <td class="vars_value">@icon-next</td>
// <td class="vars_value">'' | false | icon</td>
// <td>Breadcrumbs separating icon symbol</td>
// </tr>
// <tr>
// <th>@_icon-font</th>
// <td>@breadcrumbs-icon__font</td>
// <td class="vars_value">@icon-font</td>
// <td class="vars_value">'' | false | font</td>
// <td>Breadcrumbs separating icon font</td>
// </tr>
// <tr>
// <th>@_icon-font-size</th>
// <td>@breadcrumbs-icon__font-size</td>
// <td class="vars_value">24px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs separating icon font size</td>
// </tr>
// <tr>
// <th>@_icon-font-line-height</th>
// <td>@breadcrumbs-icon__font-line-height</td>
// <td class="vars_value">18px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs separating icon line height</td>
// </tr>
// <tr>
// <th>@_icon-font-color</th>
// <td>@breadcrumbs-icon__font-color</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs separating icon color</td>
// </tr>
// <tr>
// <th>@_icon-font-margin</th>
// <td>@breadcrumbs-icon__font-margin</td>
// <td class="vars_value">0</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs separating icon margin</td>
// </tr>
// <tr>
// <th>@_icon-font-vertical-align</th>
// <td>@breadcrumbs-icon__font-vertical-align</td>
// <td class="vars_value">top</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs separating icon vertical align</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Breadcrumbs - current page</th>
// </tr>
// <tr>
// <th>@_breadcrumbs-current-color</th>
// <td>@breadcrumbs-current__color</td>
// <td class="vars_value">#a3a3a3</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs current page color</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-current-font-weight</th>
// <td>@breadcrumbs-current__font-weight</td>
// <td class="vars_value">@font-weight__regular</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs current page font weight</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-current-background</th>
// <td>@breadcrumbs-current__background</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs current page background</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-current-border</th>
// <td>@breadcrumbs-current__border</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs current page border</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-current-gradient</th>
// <td>@breadcrumbs-current__gradient</td>
// <td class="vars_value">false</td>
// <td class="vars_value">true | false</td>
// <td>Breadcrumbs current page have gradient background</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-current-gradient-direction</th>
// <td>@breadcrumbs-current__gradient-direction</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | vertical | horizontal</td>
// <td>Direction of breadcrumbs current page background gradient (if there is any)</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-current-gradient-color-start</th>
// <td>@breadcrumbs-current__gradient-color-start</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs current page gradient start color</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-current-gradient-color-end</th>
// <td>@breadcrumbs-current__gradient-color-end</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs current page gradient end color</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Breadcrumbs link</th>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-gradient</th>
// <td>@breadcrumbs-link__gradient</td>
// <td class="vars_value">false</td>
// <td class="vars_value">true | false</td>
// <td>Breadcrumbs items have gradient background</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-gradient-direction</th>
// <td>@breadcrumbs-link__gradient-direction</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | vertical | horizontal</td>
// <td>Direction of breadcrumbs item background gradient (if there is any)</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Breadcrumbs link - default</th>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-color</th>
// <td>@breadcrumbs-link__color</td>
// <td class="vars_value">@primary__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item color</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-background</th>
// <td>@breadcrumbs-link__background</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item background</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-border</th>
// <td>@breadcrumbs-link__border</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item border</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-text-decoration</th>
// <td>@breadcrumbs-link__text-decoration</td>
// <td class="vars_value">none</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item text decoration</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-gradient-color-start</th>
// <td>@breadcrumbs-link__gradient-color-start</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item gradient start color</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-gradient-color-end</th>
// <td>@breadcrumbs-link__gradient-color-end</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item gradient end color</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Breadcrumbs link - visited</th>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-color-visited</th>
// <td>@breadcrumbs-link__visited__color</td>
// <td class="vars_value">@primary__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item visited color</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-background-visited</th>
// <td>@breadcrumbs-link__visited__background</td>
// <td class="vars_value">@breadcrumbs-link__background</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item visited background</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-border-visited</th>
// <td>@breadcrumbs-link__visited__border</td>
// <td class="vars_value">@breadcrumbs-link__border</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item visited border</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-text-decoration-visited</th>
// <td>@breadcrumbs-link__visited__text-decoration</td>
// <td class="vars_value">none</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item text decoration</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-gradient-color-start-visited</th>
// <td>@breadcrumbs-link__visited__gradient-color-start</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item visited gradient start color</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-gradient-color-end-visited</th>
// <td>@breadcrumbs-link__visited__gradient-color-end</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item visited gradient end color</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Breadcrumbs link - hover</th>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-color-hover</th>
// <td>@breadcrumbs-link__hover__color</td>
// <td class="vars_value">@primary__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item hover color</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-background-hover</th>
// <td>@breadcrumbs-link__hover__background</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item hover background</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-border-hover</th>
// <td>@breadcrumbs-link__hover__border</td>
// <td class="vars_value">@breadcrumbs-link__border</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item hover border</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-text-decoration-hover</th>
// <td>@breadcrumbs-link__hover__text-decoration</td>
// <td class="vars_value">underline</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item hover text decoration</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-gradient-color-start-hover</th>
// <td>@breadcrumbs-link__hover__gradient-color-start</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item hover gradient start color</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-gradient-color-end-hover</th>
// <td>@breadcrumbs-link__hover__gradient-color-end</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item hover gradient end color</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Breadcrumbs link - active</th>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-color-active</th>
// <td>@breadcrumbs-link__active__color</td>
// <td class="vars_value">@primary__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item active color</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-background-active</th>
// <td>@breadcrumbs-link__active__background</td>
// <td class="vars_value">@breadcrumbs-link__background</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item active background</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-border-active</th>
// <td>@breadcrumbs-link__active__border</td>
// <td class="vars_value">@breadcrumbs-link__border</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item active border</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-text-decoration-active</th>
// <td>@breadcrumbs-link__active__text-decoration</td>
// <td class="vars_value">none</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item active text decoration</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_breadcrumbs-link-gradient-color-start-active</th>
// <td>@breadcrumbs-link__active__gradient-color-start</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item active gradient start color</td>
// </tr>
// <tr>
// <th>@_breadcrumbs-link-gradient-color-end-active</th>
// <td>@breadcrumbs-link__active__gradient-color-end</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Breadcrumbs item active gradient end color</td>
// </tr>
// </table>
// </pre>
//
// # Button-styled breadcrumbs with gradient background, border, and no separating symbol
//
// Set values for the following variables to:
//
// hide separating symbol:
// ```css
// @_breadcrumbs-separator-symbol: ''
// ```
// set up links gradient background for default and hover state:
// ```css
// @_breadcrumbs-link-gradient: true,
// @_breadcrumbs-link-gradient-direction: vertical,
// @_breadcrumbs-link-gradient-color-start: #f4f4f4,
// @_breadcrumbs-link-gradient-color-end: #ccc,
// @_breadcrumbs-link-gradient-color-start-hover: #ccc,
// @_breadcrumbs-link-gradient-color-end-hover: #f4f4f4
// ```
// set up current page gradient background:
// ```css
// @_breadcrumbs-current-gradient: true,
// @_breadcrumbs-current-gradient-color-start: #f7b32e,
// @_breadcrumbs-current-gradient-color-end: #ff5501
// ```
// ```html
// <div class="example-breadcrumbs-2">
// <ul class="items">
// <li class="item home">
// <a title="Go to Home Page" href="#">Home</a>
// </li>
// <li class="item category1">
// <a title="Category" href="#">Category</a>
// </li>
// <li class="item category2">
// <a title="Category" href="#">Subcategory</a>
// </li>
// <li class="item category3">
// <strong>Products</strong>
// </li>
// </ul>
// </div>
// ```
.example-breadcrumbs-2 {
.lib-breadcrumbs(
@_breadcrumbs-separator-symbol: '',
@_breadcrumbs-display: inline-block,
@_breadcrumbs-padding: 3px 5px,
@_breadcrumbs-link-border: 1px solid #ccc,
@_breadcrumbs-link-gradient: true,
@_breadcrumbs-link-gradient-direction: vertical,
@_breadcrumbs-link-gradient-color-start: #f4f4f4,
@_breadcrumbs-link-gradient-color-end: #ccc,
@_breadcrumbs-link-gradient-color-start-hover: #ccc,
@_breadcrumbs-link-gradient-color-end-hover: #f4f4f4,
@_breadcrumbs-link-text-decoration-hover: none,
@_breadcrumbs-current-color: #1979c3,
@_breadcrumbs-current-gradient: true,
@_breadcrumbs-current-gradient-color-start: #f7b32e,
@_breadcrumbs-current-gradient-color-end: #ff5501,
@_breadcrumbs-current-border: 1px solid #d04b0a
);
}
// # Breadcrumbs with solid background
//
// Breadcrumbs with solid background and a triangle right on the right side, without separating symbol.
//
// Set values for the following variables to:
//
// hide separating symbol use:
// ```css
// @_breadcrumbs-separator-symbol: ''
// ```
// set up solid background for links for default and hover state:
// ```css
// @_breadcrumbs-link-background: #f4f4f4,
// @_breadcrumbs-link-background-hover: #ccc
// ```
// set up gradient background for current page:
// ```css
// @_breadcrumbs-current-background: #e7e7e7,
// @_breadcrumbs-current-color: #333,
// ```
//
// User can also add customization that was not provided with the breadcrumbs mixin. Here we can add solid arrow right for each link:
// ```html
// <div class="example-breadcrumbs-3">
// <ul class="items">
// <li class="item home">
// <a title="Go to Home Page" href="#">Home</a>
// </li>
// <li class="item category1">
// <a title="Category" href="#">Category</a>
// </li>
// <li class="item category2">
// <a title="Category" href="#">Subcategory</a>
// </li>
// <li class="item category3">
// <strong>Products</strong>
// </li>
// </ul>
// </div>
// ```
.example-breadcrumbs-3 {
.lib-breadcrumbs(
@_breadcrumbs-separator-symbol: '',
@_breadcrumbs-display: inline-block,
@_breadcrumbs-padding: 3px 5px,
@_breadcrumbs-current-background: #e7e7e7,
@_breadcrumbs-current-color: #333,
@_breadcrumbs-link-text-decoration-hover: none,
@_breadcrumbs-link-background: #f4f4f4,
@_breadcrumbs-link-background-hover: #ccc
);
.item a {
position: relative;
margin: 0 11px 0 0;
&:after {
.lib-arrow(right, 12px, #f4f4f4);
content: "";
position: absolute;
display: block;
top: 0;
right: -23px;
}
&:hover:after {
border-color: transparent transparent transparent #ccc;
}
}
}
File diff suppressed because it is too large Load Diff
+156
View File
@@ -0,0 +1,156 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
// # Components
// Components are complete ready-for-use parts both for Storefront or Admin area.
// They are not mixins, but classes. To use them, include this file with @import.
//
// ``` less
// @import 'components/_component.less';
// ```
@import '../../source/components/_modals.less';
// ## Modals
//
// This component contains two kinds of modals: popups and slide panels.
// ### Modal popups
// To have a modal popup use <code>.lib-modal-popup</code> class.
// <textarea class="preview-code" spellcheck="false">
// <div class="modals-wrapper">
// <aside
// class="modal-popup _show"
// data-role="modal"
// data-type="popup">
// <div class="modal-inner-wrap">
// <header class="modal-header">
// <h1 class="modal-title" data-role="title">Modal Popup</h1>
// <button
// class="action-close"
// data-role="closeBtn"
// type="button">
// <span>Close</span>
// </button>
// </header>
// <div class="modal-content" data-role="content">
// Modal Content
// </div>
// <footer class="modal-content" data-role="content">
// Modal Footer
// </footer>
// </div>
// </aside>
// <div class="modals-overlay"></div>
// </div>
// </textarea>
//
// ### Modal slide panels
// To have a modal slide panel use <code>.lib-modal-slide</code> class.
// <textarea class="preview-code" spellcheck="false">
// <div class="modals-wrapper">
// <aside
// class="modal-slide _show"
// data-role="modal"
// data-type="slide">
// <div class="modal-inner-wrap">
// <header class="modal-header">
// <h1 class="modal-title" data-role="title">Modal Slide</h1>
// <button
// class="action-close"
// data-role="closeBtn"
// type="button">
// <span>Close</span>
// </button>
// </header>
// <div class="modal-content" data-role="content">
// Modal Content
// </div>
// <footer class="modal-content" data-role="content">
// Modal Footer
// </footer>
// </div>
// </aside>
// <div class="modals-overlay"></div>
// </div>
// </textarea>
// # Components Variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowable values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@modal__background-color</th>
// <td class="vars_value">@color-white</td>
// <td class="vars_value">constant</td>
// <td>Modal background color</td>
// </tr>
// <tr>
// <th>@modal__box-shadow</th>
// <td class="vars_value">0 0 12px 2px rgba(0, 0, 0, .35)</td>
// <td class="vars_value">constant</td>
// <td>Modal shadow</td>
// </tr>
// <tr>
// <th class="vars_section" colspan="4">Popups</th>
// </tr>
// <tr>
// <th>@modal-popup__indent-vertical</th>
// <td class="vars_value">5rem</td>
// <td class="vars_value">constant</td>
// <td>Modal popup top window indent</td>
// </tr>
// <tr>
// <th>@modal-popup__padding</th>
// <td class="vars_value">5rem</td>
// <td class="vars_value">constant</td>
// <td>Modal popup inner indent</td>
// </tr>
// <tr>
// <th>@modal-popup__width</th>
// <td class="vars_value">75%</td>
// <td class="vars_value">constant</td>
// <td>Modal popup width</td>
// </tr>
// <tr>
// <th>@modal-popup__z-index</th>
// <td class="vars_value">@modal__z-index</td>
// <td class="vars_value">constant</td>
// <td>Modal popup z-index</td>
// </tr>
// <tr>
// <th class="vars_section" colspan="4">Slide panels</th>
// </tr>
// <tr>
// <th>@modal-slide__first__indent-left</th>
// <td class="vars_value">14.8rem</td>
// <td class="vars_value">constant</td>
// <td>Modal first slide window indent</td>
// </tr>
// <tr>
// <th>@modal-slide__indent-left</th>
// <td class="vars_value">4.5rem</td>
// <td class="vars_value">constant</td>
// <td>Indent between modal slide panels</td>
// </tr>
// <tr>
// <th>@modal-slide__padding</th>
// <td class="vars_value">2.6rem</td>
// <td class="vars_value">constant</td>
// <td>Modal popup inner indent</td>
// </tr>
// <tr>
// <th>@modal-slide__z-index</th>
// <td class="vars_value">@modal__z-index</td>
// <td class="vars_value">constant</td>
// <td>Modal slide z-index</td>
// </tr>
// </table>
// </pre>
+954
View File
@@ -0,0 +1,954 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
// # Drop-down and split buttons mixins
//
// Magento UI library provides mixins for 2 types of drop-downs: the <code>.lib-dropdown()</code> mixin for drop-down and the <code>.lib-dropdown-split()</code> mixin for split button.
//
// # Drop-down
//
// In Magento UI library the dropdown does not depend on the toggle tag. To toggle the drop-down, the corresponding tag must have <code>class="action toggle"</code>.
//
// ## Button tag drop-down toggle
//
// To implement a drop-down using a button + drop-down, use the following markup:
//
// ```html
// <div class="actions dropdown example-dropdown-1">
// <button class="action toggle" data-mage-init='{"dropdown":{}}' data-toggle="dropdown" aria-haspopup="true">
// <span>button + dropdown</span>
// </button>
// <ul class="dropdown">
// <li>
// <span class="item">One</span>
// </li>
// <li>
// <span class="item">Two</span>
// </li>
// <li>
// <span class="item">Three</span>
// </li>
// </ul>
// </div>
// ```
.example-dropdown-1 {
.lib-dropdown();
}
// ## Span tag drop-down toggle
//
// To implement a drop-down using a span + drop-down, use the following markup:
//
// ```html
// <div class="example-dropdown-2">
// <span class="action toggle" data-mage-init='{"dropdown":{}}' data-toggle="dropdown" aria-haspopup="true">
// <span>span + dropdown</span>
// </span>
// <ul class="dropdown">
// <li>
// <span class="item">One</span>
// </li>
// <li>
// <span class="item">Two</span>
// </li>
// <li>
// <span class="item">Three</span>
// </li>
// </ul>
// </div>
// ```
.example-dropdown-2 {
.lib-dropdown();
}
// # Drop-down variables
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Global variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_toggle-selector</th>
// <td>-</td>
// <td class="vars_value">~".action.toggle"</td>
// <td class="vars_value">Selector</td>
// <td>Toggle selector</td>
// </tr>
// <tr>
// <th>@_options-selector</th>
// <td>-</td>
// <td class="vars_value">~"ul.dropdown"</td>
// <td class="vars_value">Selector</td>
// <td>Options selector</td>
// </tr>
// <tr>
// <th>@_dropdown-actions-padding</th>
// <td>@dropdown-actions__padding</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down toggle element padding</td>
// </tr>
// <tr>
// <th>@_dropdown-list-min-width</th>
// <td>@dropdown-list__min-width</td>
// <td class="vars_value">100%</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down min width value</td>
// </tr>
// <tr>
// <th>@_dropdown-list-width</th>
// <td>@dropdown-list__width</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down list width value</td>
// </tr>
// <tr>
// <th>@_dropdown-list-height</th>
// <td>@dropdown-list__height</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down list height value</td>
// </tr>
// <tr>
// <th>@_dropdown-list-margin-top</th>
// <td>@dropdown-list__margin-top</td>
// <td class="vars_value">4px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down list margin-top value</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Drop-down list</th>
// </tr>
// <tr>
// <th>@_dropdown-list-position-top</th>
// <td>@dropdown-list__position-top</td>
// <td class="vars_value">100%</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down list position: top</td>
// </tr>
// <tr>
// <th>@_dropdown-list-position-right</th>
// <td>@dropdown-list__position-right</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down list position: right</td>
// </tr>
// <tr>
// <th>@_dropdown-list-position-bottom</th>
// <td>@dropdown-list__position-bottom</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down list position: bottom</td>
// </tr>
// <tr>
// <th>@_dropdown-list-position-left</th>
// <td>@dropdown-list__position-left</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down list position: left</td>
// </tr>
// <tr>
// <th>@_dropdown-list-background</th>
// <td>@dropdown-list__background</td>
// <td class="vars_value">@color-white</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down list background</td>
// </tr>
// <tr>
// <th>@_dropdown-list-border</th>
// <td>@dropdown-list__border</td>
// <td class="vars_value">1px solid #bbb</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down list border</td>
// </tr>
// <tr>
// <th>@_dropdown-list-pointer</th>
// <td>@dropdown-list__pointer</td>
// <td class="vars_value">true</td>
// <td class="vars_value">true | false</td>
// <td>Drop-down list pointer is visible</td>
// </tr>
// <tr>
// <th>@_dropdown-list-pointer-border</th>
// <td>@dropdown-list-pointer__border</td>
// <td class="vars_value">#bbb</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down list pointer border</td>
// </tr>
// <tr>
// <th>@_dropdown-list-pointer-position</th>
// <td>@dropdown-list-pointer__position</td>
// <td class="vars_value">left</td>
// <td class="vars_value">left | right</td>
// <td>Drop-down pointer position</td>
// </tr>
// <tr>
// <th>@_dropdown-list-pointer-position-top</th>
// <td>@dropdown-list-pointer__position-top</td>
// <td class="vars_value">-12px</td>
// <td class="vars_value">value</td>
// <td>Drop-down pointer top position</td>
// </tr>
// <tr>
// <th>@_dropdown-list-pointer-position-left-right</th>
// <td>@dropdown-list-pointer__position-left-right</td>
// <td class="vars_value">10px</td>
// <td class="vars_value">value</td>
// <td>Drop-down pointer left or right position</td>
// </tr>
// <tr>
// <th>@_dropdown-list-item-border</th>
// <td>@dropdown-list-item__border</td>
// <td class="vars_value">0</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down list item border</td>
// </tr>
// <tr>
// <th>@_dropdown-list-item-padding</th>
// <td>@dropdown-list-item__padding</td>
// <td class="vars_value">3px @indent__xs</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down list item padding</td>
// </tr>
// <tr>
// <th>@_dropdown-list-item-margin</th>
// <td>@dropdown-list-item__margin</td>
// <td class="vars_value">0</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down list item margin</td>
// </tr>
// <tr>
// <th>@_dropdown-list-item-hover</th>
// <td>@dropdown-list-item__hover</td>
// <td class="vars_value">#e8e8e8</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down list item hovered background</td>
// </tr>
// <tr>
// <th>@_dropdown-list-shadow</th>
// <td>@dropdown-list__shadow</td>
// <td class="vars_value">0 3px 3px rgba(0,0,0,.15)</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down list shadow</td>
// </tr>
// <tr>
// <th>@_dropdown-list-z-index</th>
// <td>@dropdown-list__z-index</td>
// <td class="vars_value">100</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down list z-index</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Drop-down icon</th>
// </tr>
// <tr>
// <th>@_dropdown-toggle-icon-content</th>
// <td>@dropdown-toggle-icon__content</td>
// <td class="vars_value">@icon-pointer-down</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down toggle icon symbol code for default state</td>
// </tr>
// <tr>
// <th nowrap>@_dropdown-toggle-active-icon-content</th>
// <td>@dropdown-toggle-icon__active__content</td>
// <td class="vars_value">@icon-pointer-up</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down toggle icon symbol code for active state</td>
// </tr>
// <tr>
// <th>@_icon-font</th>
// <td>@dropdown-toggle-icon__font</td>
// <td class="vars_value">@button-icon__font</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down toggle icon font</td>
// </tr>
// <tr>
// <th>@_icon-font-size</th>
// <td>@dropdown-toggle-icon__font-size</td>
// <td class="vars_value">@button-icon__font-size</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down toggle icon font size</td>
// </tr>
// <tr>
// <th>@_icon-font-line-height</th>
// <td>@dropdown-toggle-icon__font-line-height</td>
// <td class="vars_value">@button-icon__line-height</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down toggle icon line height</td>
// </tr>
// <tr>
// <th>@_icon-font-color</th>
// <td>@dropdown-toggle-icon__font-color</td>
// <td class="vars_value">@button-icon__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down toggle icon color</td>
// </tr>
// <tr>
// <th>@_icon-font-color-hover</th>
// <td>@dropdown-toggle-icon__font-color-hover</td>
// <td class="vars_value">@button-icon__hover__font-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down toggle icon hovered color</td>
// </tr>
// <tr>
// <th>@_icon-font-color-active</th>
// <td>@dropdown-toggle-icon__font-color-active</td>
// <td class="vars_value">@button-icon__active__font-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down toggle icon active color</td>
// </tr>
// <tr>
// <th>@_icon-font-margin</th>
// <td>@dropdown-toggle-icon__font-margin</td>
// <td class="vars_value">@button-icon__margin</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down toggle icon margin</td>
// </tr>
// <tr>
// <th>@_icon-font-position</th>
// <td>@dropdown-toggle-icon__position</td>
// <td class="vars_value">after</td>
// <td class="vars_value">before | after</td>
// <td>Drop-down toggle icon position</td>
// </tr>
// <tr>
// <th>@_icon-font-vertical-align</th>
// <td>@dropdown-toggle-icon__font-vertical-align</td>
// <td class="vars_value" nowrap="nowrap">@button-icon__vertical-align</td>
// <td class="vars_value">'' | false | value</td>
// <td>Drop-down toggle icon vertical align</td>
// </tr>
// <tr>
// <th>@_icon-font-text-hide</th>
// <td>@dropdown-toggle-icon__text-hide</td>
// <td class="vars_value">@button-icon__text-hide</td>
// <td class="vars_value">true | false</td>
// <td>Text in the tag, that contains icon, is hidden</td>
// </tr>
// </table>
// </pre>
//
// # Drop-down with icon customization
//
// To customize drop-down icon symbol, specify variables for default state icon code and active state icon code:
// ```css
// @_dropdown-toggle-icon-content: @icon-expand,
// @_dropdown-toggle-active-icon-content: @icon-collapse
// ```
// The <code>.lib-dropdown()</code> mixin uses the <code>.icon-font()</code> mixin to display and customize toggle icon. More information about <code>.icon-font()</code> mixin parameters you can find at the **Icons** page
//
// ```html
// <div class="actions dropdown example-dropdown-3">
// <span class="action toggle" data-mage-init='{"dropdown":{}}' data-toggle="dropdown" aria-haspopup="true">
// <span>span + dropdown</span>
// </span>
// <ul class="dropdown">
// <li>
// <span class="item">One</span>
// </li>
// <li>
// <span class="item">Two</span>
// </li>
// <li>
// <span class="item">Three</span>
// </li>
// </ul>
// </div>
// ```
.example-dropdown-3 {
.lib-dropdown(
@_dropdown-toggle-icon-content: @icon-expand,
@_dropdown-toggle-active-icon-content: @icon-collapse,
@_icon-font-line-height: 1,
@_icon-font-position: before,
@_icon-font-color: #f00,
@_icon-font-color-hover: #f00
);
}
// # Modify dropdown list styles
//
// You can customize dropdown list style
//
// ```html
// <div class="actions dropdown example-dropdown-5">
// <span class="action toggle" data-mage-init='{"dropdown":{}}' data-toggle="dropdown" aria-haspopup="true">
// <span>span + dropdown</span>
// </span>
// <ul class="dropdown">
// <li>
// <span class="item">One</span>
// </li>
// <li>
// <span class="item">Two</span>
// </li>
// <li>
// <span class="item">Three</span>
// </li>
// </ul>
// </div>
// ```
.example-dropdown-5 {
.lib-dropdown(
@_dropdown-list-pointer: false,
@_dropdown-list-background: #eef1f3,
@_dropdown-list-item-hover: #d8e3e3,
@_dropdown-list-border: 2px solid #ced1d4,
@_dropdown-list-item-padding: 10px,
@_dropdown-list-item-border: 2px solid #e8eaed,
@_dropdown-list-shadow: none,
@_icon-font-line-height: 1
);
}
// # Split button
//
// Split button can be formed of two buttons or a link and a button. The first element (link or button) must have <code>class="action split"</code>, the toggle element must have <code>class="action toggle"</code>.
//
// ## Split button: button+button
//
// ```html
// <div class="actions split example-dropdown-6">
// <button class="action split">
// <span>Spit button</span>
// </button>
// <button class="action toggle" data-mage-init='{"dropdown":{}}' data-toggle="dropdown" aria-haspopup="true">
// <span>Select</span>
// </button>
// <ul class="dropdown">
// <li>
// <span class="item">One</span>
// </li>
// <li>
// <span class="item">Two</span>
// </li>
// <li>
// <span class="item">Three</span>
// </li>
// </ul>
// </div>
// ```
//
// ## Split button: link+button
//
// ```html
// <div class="actions split example-dropdown-7">
// <a href="#" class="action split">
// <span>Spit button</span>
// </a>
// <button class="action toggle" data-mage-init='{"dropdown":{}}' data-toggle="dropdown" aria-haspopup="true">
// <span>Select</span>
// </button>
// <ul class="dropdown">
// <li>
// <span class="item">One</span>
// </li>
// <li>
// <span class="item">Two</span>
// </li>
// <li>
// <span class="item">Three</span>
// </li>
// </ul>
// </div>
// ```
.example-dropdown-6 {
.lib-dropdown-split(
@_dropdown-split-button-border-radius-fix: true
);
}
.split.example-dropdown-7 {
.lib-dropdown-split();
}
// # Split button variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Global variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_toggle-selector</th>
// <td>-</td>
// <td class="vars_value">~".action.toggle"</td>
// <td class="vars_value">selector</td>
// <td>Split button action toggle selector</td>
// </tr>
// <tr>
// <th>@_options-selector</th>
// <td>-</td>
// <td class="vars_value">~"ul.dropdown"</td>
// <td class="vars_value">selector</td>
// <td>Split button options selector</td>
// </tr>
// <tr>
// <th>@_button-selector</th>
// <td>-</td>
// <td class="vars_value">~".action.split"</td>
// <td class="vars_value">selector</td>
// <td>Split button selector</td>
// </tr>
// <tr>
// <th>@_dropdown-split-actions-padding</th>
// <td>@dropdown-split-actions__padding</td>
// <td class="vars_value">0 @indent__xs</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button toggle element padding</td>
// </tr>
// <tr>
// <th>@_dropdown-split-button-actions-padding</th>
// <td>@dropdown-split-button__actions__padding</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button actions padding</td>
// </tr>
// <tr>
// <th>@_dropdown-split-toggle-actions-padding</th>
// <td>@dropdown-split-toggle__actions__padding</td>
// <td class="vars_value">4px @indent__xs</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button toggle padding</td>
// </tr>
// <tr>
// <th>@_dropdown-split-toggle-position</th>
// <td>@dropdown-split-toggle__position</td>
// <td class="vars_value">right</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button toggle element position</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Drop-down list</th>
// </tr>
// <tr>
// <th>@_dropdown-split-list-min-width</th>
// <td>@dropdown-split-list__min-width</td>
// <td class="vars_value">100%</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button min width</td>
// </tr>
// <tr>
// <th>@_dropdown-split-list-width</th>
// <td>@dropdown-split-list__width</td>
// <td class="vars_value">100%</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button width</td>
// </tr>
// <tr>
// <th>@_dropdown-split-list-height</th>
// <td>@dropdown-split-list__height</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button height</td>
// </tr>
// <tr>
// <th>@_dropdown-split-list-margin-top</th>
// <td>@dropdown-split-list__margin-top</td>
// <td class="vars_value">4px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button margin-top</td>
// </tr>
// <tr>
// <th>@_dropdown-split-list-position-top</th>
// <td>@dropdown-split-list__position-top</td>
// <td class="vars_value">@dropdown-list__position-top</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down list position: top</td>
// </tr>
// <tr>
// <th>@_dropdown-split-list-position-right</th>
// <td>@dropdown-split-list__position-right</td>
// <td class="vars_value">@dropdown-list__position-right</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down list position: right</td>
// </tr>
// <tr>
// <th>@_dropdown-split-list-position-bottom</th>
// <td>@dropdown-split-list__position-bottom</td>
// <td class="vars_value">@dropdown-list__position-bottom</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down list position: bottom</td>
// </tr>
// <tr>
// <th>@_dropdown-split-list-position-left</th>
// <td>@dropdown-split-list__position-left</td>
// <td class="vars_value">@dropdown-list__position-left</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down list position: left</td>
// </tr>
// <tr>
// <th>@_dropdown-split-list-background</th>
// <td>@dropdown-split-list__background</td>
// <td class="vars_value">@dropdown-list__background</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down background</td>
// </tr>
// <tr>
// <th>@_dropdown-split-list-border</th>
// <td>@dropdown-split-list__border</td>
// <td class="vars_value">@dropdown-list__border</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down border</td>
// </tr>
// <tr>
// <th>@_dropdown-split-list-pointer</th>
// <td>@dropdown-split-list__pointer</td>
// <td class="vars_value">@dropdown-list__pointer</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down list pointer</td>
// </tr>
// <tr>
// <th>@_dropdown-split-list-pointer-border</th>
// <td>@dropdown-split-list__pointer-border</td>
// <td class="vars_value">@dropdown-list-pointer__border</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down list pointer border</td>
// </tr>
// <tr>
// <th>@_dropdown-split-button-border-radius-fix</th>
// <td>@dropdown-split-button__border-radius-fix</td>
// <td class="vars_value">false</td>
// <td class="vars_value">true | false</td>
// <td>Split button drop-down list item border</td>
// </tr>
// <tr>
// <th>@_dropdown-split-list-item-border</th>
// <td>@dropdown-split-list__item-border</td>
// <td class="vars_value">@dropdown-list-item__border</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down list item border</td>
// </tr>
// <tr>
// <th>@_dropdown-split-list-item-padding</th>
// <td>@dropdown-split-list__item-padding</td>
// <td class="vars_value">@dropdown-list-item__padding</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down list item padding</td>
// </tr>
// <tr>
// <th>@_dropdown-split-list-item-margin</th>
// <td>@dropdown-split-list__item-margin</td>
// <td class="vars_value">@dropdown-list-item__margin</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down list item margin</td>
// </tr>
// <tr>
// <th>@_dropdown-split-list-item-hover</th>
// <td>@dropdown-split-list__item-hover</td>
// <td class="vars_value">@dropdown-list-item__hover</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down list item hovered background</td>
// </tr>
// <tr>
// <th>@_dropdown-split-list-pointer-position</th>
// <td>@dropdown-split-list__pointer-position</td>
// <td class="vars_value">right</td>
// <td class="vars_value">left | right</td>
// <td>Split button drop-down list pointer position</td>
// </tr>
// <tr>
// <th>@_dropdown-split-list-pointer-position-top</th>
// <td>@dropdown-split-list__pointer-position-top</td>
// <td class="vars_value">-12px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down list pointer position top</td>
// </tr>
// <tr>
// <th>@_dropdown-split-list-pointer-position-left-right</th>
// <td>@dropdown-split-list__pointer-position-left-right</td>
// <td class="vars_value">10px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down list pointer left or right position</td>
// </tr>
// <tr>
// <th>@_dropdown-split-list-shadow</th>
// <td>@dropdown-split-list__shadow</td>
// <td class="vars_value">@dropdown-list__shadow</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down list shadow</td>
// </tr>
// <tr>
// <th>@_dropdown-split-list-z-index</th>
// <td>@dropdown-split-list__z-index</td>
// <td class="vars_value">@dropdown-list__z-index</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down list z-index</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Dropdown icon</th>
// </tr>
// <tr>
// <th>@_dropdown-split-toggle-icon-content</th>
// <td>@dropdown-split-toggle-icon__content</td>
// <td class="vars_value">@dropdown-toggle-icon__content</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down toggle icon - default state</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_dropdown-split-toggle-active-icon-content</th>
// <td>@dropdown-split-toggle-icon__active__content</td>
// <td class="vars_value" nowrap="nowrap">@dropdown-toggle-icon__active__content</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down toggle icon - active state</td>
// </tr>
// <tr>
// <th>@_icon-font</th>
// <td>@dropdown-split-toggle-icon__font</td>
// <td class="vars_value">@button-icon__font</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down toggle icon font</td>
// </tr>
// <tr>
// <th>@_icon-font-size</th>
// <td>@dropdown-split-toggle-icon__font-size</td>
// <td class="vars_value">@button-icon__font-size</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down toggle icon font size</td>
// </tr>
// <tr>
// <th>@_icon-font-line-height</th>
// <td>@dropdown-split-toggle-icon__font-line-height</td>
// <td class="vars_value">@button-icon__line-height</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down toggle icon line height</td>
// </tr>
// <tr>
// <th>@_icon-font-color</th>
// <td>@dropdown-split-toggle-icon__font-color</td>
// <td class="vars_value">@button-icon__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down toggle icon color</td>
// </tr>
// <tr>
// <th>@_icon-font-color-hover</th>
// <td>@dropdown-split-toggle-icon__font-color-hover</td>
// <td class="vars_value">@button-icon__hover__font-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down toggle icon hovered color</td>
// </tr>
// <tr>
// <th>@_icon-font-color-active</th>
// <td>@dropdown-split-toggle-icon__font-color-active</td>
// <td class="vars_value">@button-icon__active__font-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down toggle icon active color</td>
// </tr>
// <tr>
// <th>@_icon-font-margin</th>
// <td>@dropdown-split-toggle-icon__font-margin</td>
// <td class="vars_value">@button-icon__margin</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down toggle icon margin</td>
// </tr>
// <tr>
// <th>@_icon-font-position</th>
// <td>@dropdown-split-toggle-icon__position</td>
// <td class="vars_value">after</td>
// <td class="vars_value">before | after</td>
// <td>Split button drop-down toggle icon position</td>
// </tr>
// <tr>
// <th>@_icon-font-vertical-align</th>
// <td>@dropdown-split-toggle-icon__font-vertical-align</td>
// <td class="vars_value" nowrap="nowrap">@button-icon__vertical-align</td>
// <td class="vars_value">'' | false | value</td>
// <td>Split button drop-down toggle icon vertical align</td>
// </tr>
// <tr>
// <th>@_icon-font-text-hide</th>
// <td>@dropdown-split-toggle-icon__text-hide</td>
// <td class="vars_value">@button-icon__text-hide</td>
// <td class="vars_value">true | false</td>
// <td>The text in the toggle tag is hidden</td>
// </tr>
// </table>
// </pre>
// #Split button - button styling
//
// Split buttons can be customized the same way as all types of buttons from Magento UI library.
//
// **Regular button:**
//
// ```html
// <div class="actions split example-dropdown-8">
// <button class="action split">
// <span>Spit button</span>
// </button>
// <button class="action toggle" data-mage-init='{"dropdown":{}}' data-toggle="dropdown" aria-haspopup="true">
// <span>Select</span>
// </button>
// <ul class="dropdown">
// <li>
// <span class="item">One</span>
// </li>
// <li>
// <span class="item">Two</span>
// </li>
// <li>
// <span class="item">Three</span>
// </li>
// </ul>
// </div>
// ```
//
// **Big button:**
//
// ```html
// <div class="actions split example-dropdown-9">
// <button class="action split">
// <span>Spit button</span>
// </button>
// <button class="action toggle" data-mage-init='{"dropdown":{}}' data-toggle="dropdown" aria-haspopup="true">
// <span>Select</span>
// </button>
// <ul class="dropdown">
// <li>
// <span class="item">One</span>
// </li>
// <li>
// <span class="item">Two</span>
// </li>
// <li>
// <span class="item">Three</span>
// </li>
// </ul>
// </div>
// ```
//
// **Small button:**
//
// ```html
// <div class="actions split example-dropdown-10">
// <button class="action split">
// <span>Spit button</span>
// </button>
// <button class="action toggle" data-mage-init='{"dropdown":{}}' data-toggle="dropdown" aria-haspopup="true">
// <span>Select</span>
// </button>
// <ul class="dropdown">
// <li>
// <span class="item">One</span>
// </li>
// <li>
// <span class="item">Two</span>
// </li>
// <li>
// <span class="item">Three</span>
// </li>
// </ul>
// </div>
// ```
.example-dropdown-8 {
.lib-dropdown-split(@_dropdown-split-button-border-radius-fix: true);
}
.example-dropdown-9 {
.action.split,
.action.toggle {
.lib-button-l();
}
.lib-dropdown-split(@_dropdown-split-button-border-radius-fix: true);
}
.example-dropdown-10 {
.action.split,
.action.toggle {
.lib-button-s();
}
.lib-dropdown-split(@_dropdown-split-button-border-radius-fix: true);
}
// # Split button icon customization
//
// Mixin <code>.lib-dropdown-split()</code> uses <code>.icon-font()</code> mixin to customize icon. More information about <code>.icon-font()</code> parameters you can find at **Icons** page
//
// ```html
// <div class="actions split example-dropdown-11">
// <button class="action split">
// <span>Spit button</span>
// </button>
// <button class="action toggle" data-mage-init='{"dropdown":{}}' data-toggle="dropdown" aria-haspopup="true">
// <span>Select</span>
// </button>
// <ul class="dropdown">
// <li>
// <span class="item">One</span>
// </li>
// <li>
// <span class="item">Two</span>
// </li>
// <li>
// <span class="item">Three</span>
// </li>
// </ul>
// </div>
// ```
.example-dropdown-11 {
.lib-dropdown-split(
@_dropdown-split-toggle-position: left,
@_dropdown-split-button-border-radius-fix: true,
@_dropdown-split-toggle-icon-content: @icon-expand,
@_dropdown-split-toggle-active-icon-content: @icon-collapse,
@_icon-font-position: before,
@_icon-font-color: #f00,
@_icon-font-color-hover: #f00
);
}
// # Split button drop-down list customization
//
// You can customize drop-down list style
//
// ```html
// <div class="actions split example-dropdown-12">
// <button class="action split">
// <span>Spit button</span>
// </button>
// <button class="action toggle" data-mage-init='{"dropdown":{}}' data-toggle="dropdown" aria-haspopup="true">
// <span>Select</span>
// </button>
// <ul class="dropdown">
// <li>
// <span class="item">One</span>
// </li>
// <li>
// <span class="item">Two</span>
// </li>
// <li>
// <span class="item">Three</span>
// </li>
// </ul>
// </div>
// ```
.example-dropdown-12 {
.lib-dropdown-split(
@_dropdown-split-list-pointer: false,
@_dropdown-split-list-background: #eef1f3,
@_dropdown-split-list-item-hover: #d8e3e3,
@_dropdown-split-list-border: 2px solid #ced1d4,
@_dropdown-split-list-item-padding: 10px,
@_dropdown-split-list-item-border: 2px solid #e8eaed,
@_dropdown-split-list-shadow: none,
@_dropdown-split-button-border-radius-fix: true
);
}
File diff suppressed because it is too large Load Diff
+912
View File
@@ -0,0 +1,912 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
// # Icons
// Icons can be represented by using the fonts, images, or sprites.
//
// An icon can be added to any HTML tag. For this purpose you need to use additional <code>&lt;span&gt;</code> tag within your tag. This additional tag serves for displaying an icon without visible text, thus following the **accessibility requirements**. Then you need to apply appropriate <code>icon</code> mixin for this tag's class. Icon can be added both before and after element's text. Also, icon can be displayed instead of element's text (in this case the text is hidden).
//
// There are two ways to insert icon: first you can use **sprite or image**, second you can use **an icon font**. Magento UI library provides mixins for both of them.
// ```
// <a href="#" class="example-icon-1"><span>sprite icon before the text</span></a>
// <br>
// <a href="#" class="example-icon-2"><span>sprite icon after the text</span></a>
// <br>
// <a href="#" class="example-icon-3" title="sprite icon instead of the text"><span>icon instead of the text</span></a>
// <br>
// <a href="#" class="example-icon-4"><span>font icon before the text</span></a>
// <br>
// <a href="#" class="example-icon-5"><span>font icon after the text</span></a>
// <br>
// <a href="#" class="example-icon-6" title="font icon instead of the text"><span>icon instead of the text</span></a>
// ```
.example-icon-1 {
.lib-icon-image(@_icon-image: '@{baseDir}images/blank-theme-icons.png');
}
.example-icon-2 {
.lib-icon-image(
@_icon-image: '@{baseDir}images/blank-theme-icons.png',
@_icon-image-position-x: -26px,
@_icon-image-position-y: 0,
@_icon-image-position: after
);
}
.example-icon-3 {
.lib-icon-image(
@_icon-image: '@{baseDir}images/blank-theme-icons.png',
@_icon-image-position-x: -156px,
@_icon-image-position-y: -52px,
@_icon-image-text-hide: true
);
}
.example-icon-4 {
.lib-icon-font(
@_icon-font-content: @icon-settings,
@_icon-font-size: 24px
);
}
.example-icon-5 {
.lib-icon-font(
@_icon-font-content: @icon-star,
@_icon-font-size: 24px,
@_icon-font-position: after
);
}
.example-icon-6 {
.lib-icon-font(
@_icon-font-content: @icon-flag,
@_icon-font-size: 24px,
@_icon-font-text-hide: true
);
}
// # Icon with image or sprite
// the <code>.lib-icon-image()</code> mixin is used to create icons using single image or sprite. It has one mandatory parameter - <code>@_icon-image</code>. This parameter accepts the path to an image or sprite.
//
// ```
// <a href="#" class="example-icon-7"><span>icon-search</span></a>
// ```
.example-icon-7 {
.lib-icon-image(@_icon-image: '@{baseDir}images/blank-theme-icons.png');
}
// # Icon with image or sprite variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Global variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_icon-image</th>
// <td>-</td>
// <td class="vars_value">-</td>
// <td class="vars_value">'' | false | value</td>
// <td>A link to an image or sprite, mandatory parameter</td>
// </tr>
// <tr>
// <th>@_icon-image-height</th>
// <td>@icon__height</td>
// <td class="vars_value">26px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Icon image height</td>
// </tr>
// <tr>
// <th>@_icon-image-width</th>
// <td>@icon__width</td>
// <td class="vars_value">26px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Icon image width</td>
// </tr>
// <tr>
// <th>@_icon-image-margin</th>
// <td>@icon__margin</td>
// <td class="vars_value">0</td>
// <td class="vars_value">'' | false | value</td>
// <td>Icon image margin</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_icon-image-vertical-align</th>
// <td>@icon__vertical-align</td>
// <td class="vars_value">middle</td>
// <td class="vars_value">'' | false | value</td>
// <td>Icon image vertical align</td>
// </tr>
// <tr>
// <th>@_icon-image-position-x</th>
// <td>@icon-image__position-x</td>
// <td class="vars_value">0</td>
// <td class="vars_value">'' | false | value</td>
// <td>Horizontal image position</td>
// </tr>
// <tr>
// <th>@_icon-image-position-y</th>
// <td>@icon-image__position-y</td>
// <td class="vars_value">0</td>
// <td class="vars_value">'' | false | value</td>
// <td>Vertical image position</td>
// </tr>
// <tr>
// <th>@_icon-image-position</th>
// <td>@icon__position</td>
// <td class="vars_value">before</td>
// <td class="vars_value">before | after</td>
// <td>Icon image position</td>
// </tr>
// <tr>
// <th>@_icon-image-text-hide</th>
// <td>@icon__text-hide</td>
// <td class="vars_value">false</td>
// <td class="vars_value">true | false</td>
// <td>The text in the &lt;span&gt; tag should be hidden</td>
// </tr>
// </table>
// </pre>
// # Icon position for an icon with image or sprite
// To change the position for icons with image the <code>.lib-icon-image-position()</code> mixin is used. By managing its <code>@_icon-image-position-x</code> and <code>@_icon-image-position-y</code> variables you can move the image on element's background. The <code>@_icon-image-position</code> variable is used to define the position of icon (before or after the element).
// ```
// <a href="#" class="example-icon-8"><span>icon-star</span></a>
// <br>
// <a href="#" class="example-icon-9"><span>icon-heart</span></a>
// ```
.example-icon-8 {
.lib-icon-image(@_icon-image: '@{baseDir}images/blank-theme-icons.png');
.lib-icon-image-position(
@_icon-image-position-x: -182px
);
}
.example-icon-9 {
.lib-icon-image(@_icon-image: '@{baseDir}images/blank-theme-icons.png', @_icon-image-position: after);
.lib-icon-image-position(
@_icon-image-position-x: -52px,
@_icon-image-position-y: -26px,
@_icon-image-position: after
);
}
// # Position for icon with image or sprite mixin variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Global variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_icon-image-position-x</th>
// <td>@icon-image__position-x</td>
// <td class="vars_value">0</td>
// <td class="vars_value">'' | false | value</td>
// <td>Horizontal starting position of icon image</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_icon-image-position-y</th>
// <td>@icon-image__position-y</td>
// <td class="vars_value">0</td>
// <td class="vars_value">'' | false | value</td>
// <td>Vertical starting position of icon image</td>
// </tr>
// <tr>
// <th>@_icon-image-position</th>
// <td>@icon__position</td>
// <td class="vars_value">before</td>
// <td class="vars_value">before | after</td>
// <td>Position of the icon which is set for the element</td>
// </tr>
// </table>
// </pre>
// # Icon sprite position (with grid)
// Mixin <code>.lib-icon-sprite-position()</code> is used to manage the position of sprite background image. It assumes the use of a single sprite image with individual images **placed on a regular grid**.
// ```
// <a href="#" class="example-icon-10"><span>icon text</span></a>
// ```
.example-icon-10 {
.lib-icon-image(@_icon-image: '@{baseDir}images/blank-theme-icons.png');
.lib-icon-sprite-position(4, 0);
}
// # Icon sprite position variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Global variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_icon-sprite-position-x</th>
// <td>@icon-sprite__position-x</td>
// <td class="vars_value">0</td>
// <td class="vars_value">'' | false | value</td>
// <td>The x coordinate of the desired image on the grid</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_icon-sprite-position-y</th>
// <td>@icon-sprite__position-y</td>
// <td class="vars_value">0</td>
// <td class="vars_value">'' | false | value</td>
// <td>The y coordinate of the desired image on the grid</td>
// </tr>
// <tr>
// <th>@_icon-sprite-grid</th>
// <td>@icon-sprite__grid</td>
// <td class="vars_value">26px</td>
// <td class="vars_value">'' | false | value</td>
// <td>The size of the grid (in pixels) that the individual images are placed on</td>
// </tr>
// <tr>
// <th>@_icon-sprite-position</th>
// <td>@icon__position</td>
// <td class="vars_value">before</td>
// <td class="vars_value">before | after</td>
// <td>Icon image position</td>
// </tr>
// </table>
// </pre>
// # Image/sprite icon size
// Mixin <code>.lib-icon-image-size()</code> is used to change the image/sprite icon size
// ```
// <a href="#" class="example-icon-11"><span>icon-search</span></a>
// ```
.example-icon-11 {
.lib-icon-image(@_icon-image: '@{baseDir}images/blank-theme-icons.png');
.lib-icon-image-size(30px, 30px);
&:before {
background-color: #f1f1f1;
}
}
// # Image/sprite icon size variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Global variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_icon-image-width</th>
// <td>@icon__width</td>
// <td class="vars_value">26px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Icon image width</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_icon-image-height</th>
// <td>@icon__height</td>
// <td class="vars_value">26px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Icon image height</td>
// </tr>
// <tr>
// <th>@_icon-image-position</th>
// <td>@icon__position</td>
// <td class="vars_value">before</td>
// <td class="vars_value">before | after</td>
// <td>Icon image position</td>
// </tr>
// </table>
// </pre>
//
// # Font icon
// The <code>.lib-icon-font()</code> mixin is used to create icons using font icons. It has one mandatory parameter - <code>@_icon-font-content</code>. This parameter accepts the font icon code.
//
// ```
// <a href="#" class="example-icon-12"><span>icon-calendar</span></a>
// ```
.example-icon-12 {
.lib-icon-font(
@icon-calendar,
@_icon-font-size: 28px
);
}
// # Font icon variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Global variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_icon-font-content</th>
// <td>-</td>
// <td class="vars_value">&nbsp;</td>
// <td class="vars_value">'' | icon code | icon variables</td>
// <td>Font icon code</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_icon-font</th>
// <td>@icon-font</td>
// <td class="vars_value">@icons__font-name</td>
// <td class="vars_value">'' | false | value</td>
// <td>The icon font</td>
// </tr>
// <tr>
// <th>@_icon-font-size</th>
// <td>@icon-font__size</td>
// <td class="vars_value">inherit</td>
// <td class="vars_value">'' | false | value</td>
// <td>Font icon size</td>
// </tr>
// <tr>
// <th>@_icon-font-line-height</th>
// <td>@icon-font__line-height</td>
// <td class="vars_value">@icon-font__size</td>
// <td class="vars_value">'' | false | value</td>
// <td>Font icon line height</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_icon-font-color</th>
// <td>@icon-font__color</td>
// <td class="vars_value">inherit</td>
// <td class="vars_value">'' | inherit | color code</td>
// <td>Font icon color</td>
// </tr>
// <tr>
// <th>@_icon-font-color-hover</th>
// <td>@icon-font__color-hover</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | inherit | color code</td>
// <td>Font icon color - hover state</td>
// </tr>
// <tr>
// <th>@_icon-font-color-active</th>
// <td>@icon-font__color-active</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | inherit | color code</td>
// <td>Font icon color - active state</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_icon-font-margin</th>
// <td>@icon-font__margin</td>
// <td class="vars_value">@icon__margin</td>
// <td class="vars_value">'' | false | value</td>
// <td>Font icon margin</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_icon-font-vertical-align</th>
// <td>@icon-font__vertical-align</td>
// <td class="vars_value" nowrap="nowrap">@icon__vertical-align</td>
// <td class="vars_value">'' | false | value</td>
// <td>Font icon vertical align</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_icon-font-position</th>
// <td>@icon-font__position</td>
// <td class="vars_value">@icon__position</td>
// <td class="vars_value">before | after</td>
// <td>Font icon position</td>
// </tr>
// <tr>
// <th>@_icon-font-text-hide</th>
// <td>@icon-font__text-hide</td>
// <td class="vars_value">@icon__text-hide</td>
// <td class="vars_value">true | false</td>
// <td>The text of the element is replaced with the icon(true), or the icon is on the side of the text (false)</td>
// </tr>
// <tr>
// <th>@_icon-font-display</th>
// <td>@icon-font__display</td>
// <td class="vars_value">inline-block</td>
// <td class="vars_value">'' | false | value</td>
// <td>The 'display' property of the icon container</td>
// </tr>
// </table>
// </pre>
// # Change the size of font icon
// The <code>.lib-icon-font-size()</code> mixin is used to change size of the font icon which is already defined. The mixin generates only new font size and line height without any other options. @_icon-font-position variable is used to define the position of icon (before or after the element) which we want to set font size of.
//
// ```
// <a href="#" class="example-icon-13"><span>icon-calendar</span></a>
// ```
.example-icon-13 {
.lib-icon-font(@icon-calendar);
.lib-icon-font-size(
@_icon-font-size: 26px
);
}
// # Change the size of font icon variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Global variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_icon-font-size</th>
// <td>@icon-font__size</td>
// <td class="vars_value">inherit</td>
// <td class="vars_value">'' | false | value</td>
// <td>Font icon font size</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_icon-font-line-height</th>
// <td>@icon-font__line-height</td>
// <td class="vars_value">@icon-font__size</td>
// <td class="vars_value">'' | false | value</td>
// <td>Font icon line height</td>
// </tr>
// <tr>
// <th>@_icon-font-position</th>
// <td>@icon-font__position</td>
// <td class="vars_value">before</td>
// <td class="vars_value">before | after</td>
// <td>Font icon - icon position</td>
// </tr>
// </table>
// </pre>
//
// # Hide icon text
// The <code>.lib-icon-text-hide()</code> mixin can be used separately to hide text of an element that has an icon text. This mixin accepts no variables.
//
// ```
// <a href="#" class="example-icon-14"><span>icon-calendar</span></a>
// ```
.example-icon-14 {
.lib-icon-font(
@icon-envelope,
@_icon-font-size: 26px
);
.lib-icon-text-hide();
}
// # Sprite and font icons for Blank theme
// You can use the icons designed to our Blank theme, which are also available in two variants: sprite and font
// ##Icons using sprite
// ```
// <ul class="icons-image-list">
// <li>
// <span class="icon-search"><span>icon-search</span></span>
// </li>
// <li>
// <span class="icon-cart"><span>icon-cart</span></span>
// </li>
// <li>
// <span class="icon-arrow-down"><span>icon-arrow-down</span></span>
// </li>
// <li>
// <span class="icon-arrow-up"><span>icon-arrow-up</span></span>
// </li>
// <li>
// <span class="icon-grid"><span>icon-grid</span></span>
// </li>
// <li>
// <span class="icon-list"><span>icon-list</span></span>
// </li>
// <li>
// <span class="icon-remove"><span>icon-remove</span></span>
// </li>
// <li>
// <span class="icon-star"><span>icon-star</span></span>
// </li>
// <li>
// <span class="icon-pointer-down"><span>icon-pointer-down</span></span>
// </li>
// <li>
// <span class="icon-pointer-up"><span>icon-pointer-up</span></span>
// </li>
// <li>
// <span class="icon-pointer-left"><span>icon-pointer-left</span></span>
// </li>
// <li>
// <span class="icon-pointer-right"><span>icon-pointer-right</span></span>
// </li>
// <li>
// <span class="icon-compare-empty"><span>icon-compare-empty</span></span>
// </li>
// <li>
// <span class="icon-compare-full"><span>icon-compare-full</span></span>
// </li>
// <li>
// <span class="icon-wishlist-empty"><span>icon-wishlist-empty</span></span>
// </li>
// <li>
// <span class="icon-wishlist-full"><span>icon-wishlist-full</span></span>
// </li>
// <li>
// <span class="icon-update"><span>icon-update</span></span>
// </li>
// <li>
// <span class="icon-collapse"><span>icon-collapse</span></span>
// </li>
// <li>
// <span class="icon-expand"><span>icon-expand</span></span>
// </li>
// <li>
// <span class="icon-menu"><span>icon-menu</span></span>
// </li>
// <li>
// <span class="icon-prev"><span>icon-prev</span></span>
// </li>
// <li>
// <span class="icon-next"><span>icon-next</span></span>
// </li>
// <li>
// <span class="icon-settings"><span>icon-settings</span></span>
// </li>
// <li>
// <span class="icon-info"><span>icon-info</span></span>
// </li>
// <li>
// <span class="icon-checkmark"><span>icon-checkmark</span></span>
// </li>
// <li>
// <span class="icon-calendar"><span>icon-calendar</span></span>
// </li>
// <li>
// <span class="icon-comment"><span>icon-comment</span></span>
// </li>
// <li>
// <span class="icon-comment-reflected"><span>icon-comment-reflected</span></span>
// </li>
// <li>
// <span class="icon-envelope"><span>icon-envelope</span></span>
// </li>
// <li>
// <span class="icon-warning"><span>icon-warning</span></span>
// </li>
// <li>
// <span class="icon-trash"><span>icon-trash</span></span>
// </li>
// <li>
// <span class="icon-flag"><span>icon-flag</span></span>
// </li>
// <li>
// <span class="icon-location"><span>icon-location</span></span>
// </li>
// <li>
// <span class="icon-up"><span>icon-up</span></span>
// </li>
// <li>
// <span class="icon-down"><span>icon-down</span></span>
// </li>
// </ul>
// ```
//
// ## Icons using font
// ```
// <ul class="icons-font-list">
// <li>
// <span class="icon-wishlist-full" data-icon="&#xe600"><span>@icon-wishlist-full</span></span>
// </li>
// <li>
// <span class="icon-wishlist-empty" data-icon="&#xe601"><span>@icon-wishlist-empty</span></span>
// </li>
// <li>
// <span class="icon-warning" data-icon="&#xe602"><span>@icon-warning</span></span>
// </li>
// <li>
// <span class="icon-update" data-icon="&#xe603"><span>@icon-update</span></span>
// </li>
// <li>
// <span class="icon-trash" data-icon="&#xe604"><span>@icon-trash</span></span>
// </li>
// <li>
// <span class="icon-star" data-icon="&#xe605"><span>@icon-star</span></span>
// </li>
// <li>
// <span class="icon-settings" data-icon="&#xe606"><span>@icon-settings</span></span>
// </li>
// <li>
// <span class="icon-next" data-icon="&#xe608"><span>@icon-next</span></span>
// </li>
// <li>
// <span class="icon-menu" data-icon="&#xe609"><span>@icon-menu</span></span>
// </li>
// <li>
// <span class="icon-location" data-icon="&#xe60a"><span>@icon-location</span></span>
// </li>
// <li>
// <span class="icon-list" data-icon="&#xe60b"><span>@icon-list</span></span>
// </li>
// <li>
// <span class="icon-info" data-icon="&#xe60c"><span>@icon-info</span></span>
// </li>
// <li>
// <span class="icon-grid" data-icon="&#xe60d"><span>@icon-grid</span></span>
// </li>
// <li>
// <span class="icon-checkmark" data-icon="&#xe610"><span>@icon-checkmark</span></span>
// </li>
// <li>
// <span class="icon-cart" data-icon="&#xe611"><span>@icon-cart</span></span>
// </li>
// <li>
// <span class="icon-calendar" data-icon="&#xe612"><span>@icon-calendar</span></span>
// </li>
// <li>
// <span class="icon-arrow-up" data-icon="&#xe613"><span>@icon-arrow-up</span></span>
// </li>
// <li>
// <span class="icon-arrow-down" data-icon="&#xe614"><span>@icon-arrow-down</span></span>
// </li>
// <li>
// <span class="icon-search" data-icon="&#xe615"><span>@icon-search</span></span>
// </li>
// <li>
// <span class="icon-remove" data-icon="&#xe616"><span>@icon-remove</span></span>
// </li>
// <li>
// <span class="icon-prev" data-icon="&#xe617"><span>@icon-prev</span></span>
// </li>
// <li>
// <span class="icon-pointer-down" data-icon="&#xe607"><span>@icon-pointer-down</span></span>
// </li>
// <li>
// <span class="icon-pointer-up" data-icon="&#xe618"><span>@icon-pointer-up</span></span>
// </li>
// <li>
// <span class="icon-pointer-left" data-icon="&#xe61a"><span>@icon-pointer-left</span></span>
// </li>
// <li>
// <span class="icon-pointer-right" data-icon="&#xe619"><span>@icon-pointer-right</span></span>
// </li>
// <li>
// <span class="icon-flag" data-icon="&#xe61b"><span>@icon-flag</span></span>
// </li>
// <li>
// <span class="icon-collapse" data-icon="&#xe60f"><span>@icon-collapse</span></span>
// </li>
// <li>
// <span class="icon-expand" data-icon="&#xe61c"><span>@icon-expand</span></span>
// </li>
// <li>
// <span class="icon-envelope" data-icon="&#xe61d"><span>@icon-envelope</span></span>
// </li>
// <li>
// <span class="icon-compare-empty" data-icon="&#xe61f"><span>@icon-compare-empty</span></span>
// </li>
// <li>
// <span class="icon-compare-full" data-icon="&#xe61e"><span>@icon-compare-full</span></span>
// </li>
// <li>
// <span class="icon-comment" data-icon="&#xe620"><span>@icon-comment</span></span>
// </li>
// <li>
// <span class="icon-comment-reflected" data-icon="&#xe60e"><span>@icon-comment-reflected</span></span>
// </li>
// <li>
// <span class="icon-up" data-icon="&#xe621"><span>@icon-up</span></span>
// </li>
// <li>
// <span class="icon-down" data-icon="&#xe622"><span>@icon-down</span></span>
// </li>
// <li>
// <span class="icon-arrow-up-thin" data-icon="&#xe623"><span>@icon-arrow-up-thin</span></span>
// </li>
// <li>
// <span class="icon-arrow-right-thin" data-icon="&#xe624"><span>@icon-arrow-right-thin</span></span>
// </li>
// <li>
// <span class="icon-arrow-left-thin" data-icon="&#xe625"><span>@icon-arrow-left-thin</span></span>
// </li>
// <li>
// <span class="icon-arrow-down-thin" data-icon="&#xe626"><span>@icon-arrow-down-thin</span></span>
// </li>
// <li>
// <span class="icon-arrow-left-thin" data-icon="&#xe628"><span>@icon-gift-registry</span></span>
// </li>
// <li>
// <span class="icon-arrow-down-thin" data-icon="&#xe629"><span>@icon-present</span></span>
// </li>
// </ul>
// ```
.icons-image-list {
list-style: none;
padding: 0;
li {
float: left;
width: 33%;
> span {
.lib-icon-image(@_icon-image: '@{baseDir}images/blank-theme-icons.png');
}
.icon-search {
.lib-icon-sprite-position(0, 0);
}
.icon-cart {
.lib-icon-sprite-position(1, 0);
}
.icon-arrow-down {
.lib-icon-sprite-position(2, 0);
}
.icon-arrow-up {
.lib-icon-sprite-position(3, 0);
}
.icon-grid {
.lib-icon-sprite-position(4, 0);
}
.icon-list {
.lib-icon-sprite-position(5, 0);
}
.icon-remove {
.lib-icon-sprite-position(6, 0);
}
.icon-star {
.lib-icon-sprite-position(7, 0);
}
.icon-pointer-down {
.lib-icon-sprite-position(8, 0);
}
.icon-pointer-up {
.lib-icon-sprite-position(9, 0);
}
.icon-pointer-left {
.lib-icon-sprite-position(10, 0);
}
.icon-pointer-right {
.lib-icon-sprite-position(11, 0);
}
.icon-compare-empty {
.lib-icon-sprite-position(0, 1);
}
.icon-compare-full {
.lib-icon-sprite-position(1, 1);
}
.icon-wishlist-empty {
.lib-icon-sprite-position(2, 1);
}
.icon-wishlist-full {
.lib-icon-sprite-position(3, 1);
}
.icon-update {
.lib-icon-sprite-position(4, 1);
}
.icon-collapse {
.lib-icon-sprite-position(5, 1);
}
.icon-expand {
.lib-icon-sprite-position(6, 1);
}
.icon-menu {
.lib-icon-sprite-position(7, 1);
}
.icon-prev {
.lib-icon-sprite-position(8, 1);
}
.icon-next {
.lib-icon-sprite-position(9, 1);
}
.icon-settings {
.lib-icon-sprite-position(10, 1);
}
.icon-info {
.lib-icon-sprite-position(11, 1);
}
.icon-checkmark {
.lib-icon-sprite-position(0, 2);
}
.icon-calendar {
.lib-icon-sprite-position(1, 2);
}
.icon-comment {
.lib-icon-sprite-position(2, 2);
}
.icon-comment-reflected {
.lib-icon-sprite-position(3, 2);
}
.icon-envelope {
.lib-icon-sprite-position(4, 2);
}
.icon-warning {
.lib-icon-sprite-position(5, 2);
}
.icon-trash {
.lib-icon-sprite-position(6, 2);
}
.icon-flag {
.lib-icon-sprite-position(7, 2);
}
.icon-location {
.lib-icon-sprite-position(8, 2);
}
.icon-up {
.lib-icon-sprite-position(9, 2);
}
.icon-down {
.lib-icon-sprite-position(10, 2);
}
}
}
@icon-wishlist-full: '\e600';
@icon-wishlist-empty: '\e601';
@icon-warning: '\e602';
@icon-update: '\e603';
@icon-trash: '\e604';
@icon-star: '\e605';
@icon-settings: '\e606';
@icon-pointer-down: '\e607';
@icon-next: '\e608';
@icon-menu: '\e609';
@icon-location: '\e60a';
@icon-list: '\e60b';
@icon-info: '\e60c';
@icon-grid: '\e60d';
@icon-comment-reflected: '\e60e';
@icon-collapse: '\e60f';
@icon-checkmark: '\e610';
@icon-cart: '\e611';
@icon-calendar: '\e612';
@icon-arrow-up: '\e613';
@icon-arrow-down: '\e614';
@icon-search: '\e615';
@icon-remove: '\e616';
@icon-prev: '\e617';
@icon-pointer-up: '\e618';
@icon-pointer-right: '\e619';
@icon-pointer-left: '\e61a';
@icon-flag: '\e61b';
@icon-expand: '\e61c';
@icon-envelope: '\e61d';
@icon-compare-full: '\e61e';
@icon-compare-empty: '\e61f';
@icon-comment: '\e620';
@icon-up: '\e621';
@icon-down: '\e622';
@icon-arrow-up-thin: '\e623';
@icon-arrow-right-thin: '\e624';
@icon-arrow-left-thin: '\e625';
@icon-arrow-down-thin: '\e626';
.icons-font-list {
list-style: none;
padding: 0;
li {
float: left;
width: 25%;
margin-bottom: 35px;
text-align: center;
> span {
.lib-icon-font('', @_icon-font-size: 34px);
&:before {
content: attr(data-icon);
margin: 0 auto;
display: block;
}
}
}
}
+395
View File
@@ -0,0 +1,395 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
// # Layout
//
// Magento UI library provides mixins for flexible page layout customization. For simple quick layout customization global layout variables are used.
header.header {
background-color: rgba(255, 0, 0, .2);
}
.column.main {
background-color: rgba(255, 255, 0, .2);
}
.column.left {
background-color: rgba(0, 255, 255, .2);
}
.column.right {
background-color: rgba(0, 0, 255, .2);
}
footer.footer {
background-color: rgba(0, 0, 0, .2);
}
// # Layout global variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Variables list names</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowable values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@layout__width</th>
// <td class="vars_value">''</td>
// <td class="vars_value">'' | false | value</td>
// <td>Page minimum width</td>
// </tr>
// <tr>
// <th>@layout__max-width</th>
// <td class="vars_value">1280px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Page maximum width</td>
// </tr>
// <tr>
// <th>@layout-indent__width</th>
// <td class="vars_value">20px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Page indents on the left and right</td>
// </tr>
// <tr>
// <th colspan="4" class="vars_section">Class names defining different layouts</th>
// </tr>
// <tr>
// <th>@layout-class-1column</th>
// <td class="vars_value">page-layout-1column</td>
// <td class="vars_value">'' | false | <span style="white-space: nowrap">page-layout-1column</span> | <span style="white-space: nowrap">page-layout-2columns-left</span> | <span style="white-space: nowrap">page-layout-2columns-right</span> | <span style="white-space: nowrap">page-layout-3columns</span></td>
// <td>Class name for one column layout</td>
// </tr>
// <tr>
// <th>@layout-class-2columns__left</th>
// <td class="vars_value">page-layout-2columns-left</td>
// <td class="vars_value">'' | false | <span style="white-space: nowrap">page-layout-1column</span> | <span style="white-space: nowrap">page-layout-2columns-left</span> | <span style="white-space: nowrap">page-layout-2columns-right</span> | <span style="white-space: nowrap">page-layout-3columns</span></td>
// <td>Class name for two columns layout with left sidebar</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@layout-class-2columns__right</th>
// <td class="vars_value">page-layout-2columns-right</td>
// <td class="vars_value">'' | false | <span style="white-space: nowrap">page-layout-1column</span> | <span style="white-space: nowrap">page-layout-2columns-left</span> | <span style="white-space: nowrap">page-layout-2columns-right</span> | <span style="white-space: nowrap">page-layout-3columns</span></td>
// <td>Class name for two columns layout with right sidebar</td>
// </tr>
// <tr>
// <th>@layout-class-3columns</th>
// <td class="vars_value">page-layout-3columns</td>
// <td class="vars_value">'' | false | <span style="white-space: nowrap">page-layout-1column</span> | <span style="white-space: nowrap">page-layout-2columns-left</span> | <span style="white-space: nowrap">page-layout-2columns-right</span> | <span style="white-space: nowrap">page-layout-3columns</span></td>
// <td>Class name for three columns layout with left sidebar</td>
// </tr>
// <tr>
// <th colspan="4" class="vars_section">Variables used for layout grid</th>
// </tr>
// <tr>
// <th>@total-columns</th>
// <td class="vars_value">12</td>
// <td class="vars_value">'' | false | value</td>
// <td>Number of total columns in layout (i.e. <em>1, 2, 3</em>)</td>
// </tr>
// <tr>
// <th>@gutter-width</th>
// <td class="vars_value">0</td>
// <td class="vars_value">'' | false | value</td>
// <td>Distance between columns</td>
// </tr>
// <tr>
// <th colspan="4" class="vars_section">Variables for layout columns</th>
// </tr>
// <tr>
// <th>@layout-column__width</th>
// <td class="vars_value">@total-columns</td>
// <td class="vars_value">'' | false | value</td>
// <td>Sets base columns number</td>
// </tr>
// <tr>
// <th>@layout-column__sidebar-width</th>
// <td class="vars_value">2</td>
// <td class="vars_value">'' | false | value</td>
// <td>Sets sidebar width</td>
// </tr>
// <tr>
// <th>@layout-column__left-width</th>
// <td class="vars_value">@layout-column__sidebar-width</td>
// <td class="vars_value">'' | false | value</td>
// <td>Sets left column width</td>
// </tr>
// <tr>
// <th>@layout-column__right-width</th>
// <td class="vars_value">@layout-column__sidebar-width</td>
// <td class="vars_value">'' | false | value</td>
// <td>Sets right column width</td>
// </tr>
// <tr>
// <th colspan="4" class="vars_section">Variables for layout columns depending on layout used</th>
// </tr>
// <tr>
// <th>@layout-column-main__width-1</th>
// <td class="vars_value">100%</td>
// <td class="vars_value">'' | false | value</td>
// <td>Sets one column width</td>
// </tr>
// <tr>
// <th>@layout-column-main__width-2-left</th>
// <td class="vars_value">@layout-column__width - @layout-column__left-width</td>
// <td class="vars_value">'' | false | value</td>
// <td>Sets left column width</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@layout-column-main__width-2-right</th>
// <td class="vars_value">@layout-column__width - @layout-column__right-width</td>
// <td class="vars_value">'' | false | value</td>
// <td>Sets right column width</td>
// </tr>
// <tr>
// <th>@layout-column-main__width-3</th>
// <td class="vars_value">@layout-column__width - @layout-column__left-width - @layout-column__right-width</td>
// <td class="vars_value">'' | false | value</td>
// <td>Sets three columns layout main column width</td>
// </tr>
// <tr>
// <th colspan="4" class="vars_section">Settings variables</th>
// </tr>
// <tr>
// <th>@use-flex</th>
// <td class="vars_value">true</td>
// <td class="vars_value">'' | true | false</td>
// <td>Sets compatibility for browsers not supporting flex</td>
// </tr>
// <tr>
// <th>@responsive</th>
// <td class="vars_value">true</td>
// <td class="vars_value">'' | true | false</td>
// <td>Is set to true if theme has responsive layout</td>
// </tr>
// </table>
// </pre>
// # Page layouts
//
// Default properties for page columns are generated using alias mixins:
//
// <code>#lib-layout-columns</code> - sets columns container
//
// <code>#lib-layout-columns > .main()</code> - alias for main column
//
// <code>#lib-layout-columns > .left()</code> - alias for left column
//
// <code>#lib-layout-columns > .right()</code> - alias for right column
//
// <code>#lib-layout-columns > .reset()</code> - column width and order reset may be used in RWD
//
// These aliases use default class names for layouts predefined in vars (i.e. <code>@layout-class-3columns: layout-3</code>) and general column mixin *[<code>.lib-layout-column()</code>](#layout-column)*
//
// ## Three columns page layout
//
// ```html
// <div class="page-wrapper layout-3">
// <header class="header">Header</header>
// <section class="page main">
// <div class="columns">
// <div class="column main">Main column</div><!--
// --><div class="column left sidebar">Left column</div><!--
// --><div class="column right sidebar">Right column</div>
// </div>
// </section>
// <footer class="footer">Footer</footer>
// </div>
// ```
//
// ## Two columns page layout with sidebar on the left
// ```html
// <div class="page-wrapper layout-2-left">
// <header class="header">Header</header>
// <section class="page main">
// <div class="columns">
// <div class="column main">Main column</div><!--
// --><div class="column left sidebar">Left column</div>
// </div>
// </section>
// <footer class="footer">Footer</footer>
// </div>
// ```
//
// ## Two columns page layout with sidebar on the right
//
// ```html
// <div class="page-wrapper layout-2-right">
// <header class="header">Header</header>
// <section class="page main">
// <div class="columns">
// <div class="column main">Main column</div><!--
// --><div class="column right sidebar">Right column</div>
// </div>
// </section>
// <footer class="footer">Footer</footer>
// </div>
// ```
//
// ## One column page layout
//
// ```html
// <div class="page-wrapper layout-1">
// <header class="header">Header</header>
// <section class="page main">
// <div class="columns">
// <div class="column main">Main column</div>
// </div>
// </section>
// <footer class="footer">Footer</footer>
// </div>
// ```
.columns {
#lib-layout-columns();
> .column {
&:extend(.add-box-sizing all);
.lib-css(padding-bottom, @indent__xl);
}
}
@media (min-width: 600px) {
.column.main {
#lib-layout-columns > .main();
}
.column.left {
#lib-layout-columns > .left();
}
.column.right {
#lib-layout-columns > .right();
}
}
// # Layout column
//
// The <code>.layout-column()</code> mixin is used to setup page columns. It configures number, position and width of columns
//
// 3 columns layout example:
//
// ```html
// <div class="layout-example-3">
// <header class="header">Header</header>
// <section class="page main">
// <div class="columns">
// <div class="column main">Main column</div><!--
// --><div class="column left sidebar">Left column</div><!--
// --><div class="column right sidebar">Right column</div>
// </div>
// </section>
// <footer class="footer">Footer</footer>
// </div>
// ```
//
// To move main column to the left, change 2nd argument <code>@_order</code> for main and left columns:
//
// ```less
// .lib-column.main {
// .lib-layout-column(3, 1, 60%);
// }
// .lib-column.left {
// .lib-layout-column(3, 2, 20%);
// }
// ```
//
// ```html
// <div class="layout-example-3-1">
// <header class="header">Header</header>
// <section class="page main">
// <div class="columns">
// <div class="column main">Main column</div><!--
// --><div class="column left sidebar">Left column</div><!--
// --><div class="column right sidebar">Right column</div>
// </div>
// </section>
// <footer class="footer">Footer</footer>
// </div>
// ```
.layout-example-3 {
.column.main {
.lib-layout-column(3, 2, 60%);
}
.column.left {
.lib-layout-column(3, 1, 20%);
}
.column.right {
.lib-layout-column(3, 3, 20%);
}
}
.layout-example-3-1 {
.column.main {
.lib-layout-column(3, 1, 60%);
}
.column.left {
.lib-layout-column(3, 2, 20%);
}
.column.right {
.lib-layout-column(3, 3, 20%);
}
}
// # Layout column variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_layout__min-width </th>
// <td class="vars_value">number</td>
// <td>Number of total columns in layout (i.e. <em>1, 2, 3</em>)</td>
// </tr>
// <tr>
// <th>@_order</th>
// <td class="vars_value">number</td>
// <td>Order of current column</td>
// </tr>
// <tr>
// <th>@_width</th>
// <td class="vars_value">number</td>
// <td>Width set in css units (<em>20%, 300px, etc.</em>) or in <em>grid columns</em> if unit is not specified. (<em>4</em>)</td>
// </tr>
// </table>
// </pre>
// # Layout width
//
// The <code>.lib-layout-width()</code> mixin is used to set default page width of the element the mixin is applied to. It can be used to set width for the whole page wrapper or for the page elements individually like header, footer, and so on.
// # Layout width variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_layout__min-width</th>
// <td class="vars_value">''</td>
// <td class="vars_value">'' | false | value</td>
// <td>Page minimum width</td>
// </tr>
// <tr>
// <th>@_layout__max-width</th>
// <td class="vars_value">1280px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Page maximum width</td>
// </tr>
// <tr>
// <th>@_layout__indent</th>
// <td class="vars_value">20px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Page indents on the left and right</td>
// </tr>
// </table>
// </pre>
+12
View File
@@ -0,0 +1,12 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
// # Including Magento UI library to your theme
//
// The _lib.less file contains the includes of all Magento UI library files. To use Magento UI library in your theme add the following directive to the theme’s styles.less:
// ```css
// @import 'source/lib/_lib';
// ```
// The lib.less file is designed to avoid manual adding of each Magento UI library file import instruction to your theme.
+199
View File
@@ -0,0 +1,199 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
// # Loaders
// A page loader is an animation a visitor sees while the page or an element is loaded. During this time a page is blocked with overlay.
//
// Default loader markup
//
// <pre>
// <code>
// &lt;div id="example1" class="loader" data-text="Please wait..." style="display: none;"&gt;
// &lt;/div&gt;
// </code>
// </pre>
// ```html
// <div>
// <div id="example1" class="loader" data-text="Please wait..." style="display: none;"></div>
// <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.</p>
// </div>
// <button type="button" onclick="document.getElementById('example1').style='display: block;';document.getElementById('example1').parentNode.setAttribute('aria-busy','true');" style="z-index:99999; position: relative;"><span>Show</span></button>
// <button type="button" onclick="document.getElementById('example1').style='display: none;';document.getElementById('example1').parentNode.setAttribute('aria-busy','false');" style="z-index:99999; position: relative;"><span>Hide</span></button>
// ```
//
.loader {
.lib-loader();
}
// # Default loader variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Global variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_loader-overlay-background-color</th>
// <td>@loader-overlay__background-color</td>
// <td class="vars_value">rgba(255, 255, 255, .5)</td>
// <td class="vars_value">'' | false | value</td>
// <td>Loader overlay background color</td>
// </tr>
// <tr>
// <th>@_loader-overlay-z-index</th>
// <td>@loader-overlay__z-index</td>
// <td class="vars_value">9999</td>
// <td class="vars_value">'' | false | value</td>
// <td>Loader overlay background z-index</td>
// </tr>
// <tr>
// <th>@_loader-icon-width</th>
// <td>@loader-icon__width</td>
// <td class="vars_value">160px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Loader icon width</td>
// </tr>
// <tr>
// <th>@_loader-icon-height</th>
// <td>@loader-icon__height</td>
// <td class="vars_value">160px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Loader icon height</td>
// </tr>
// <tr>
// <th>@_loader-icon-background-color</th>
// <td>@loader-icon__background-color</td>
// <td class="vars_value">transparent</td>
// <td class="vars_value">'' | false | value</td>
// <td>Loader icon background color</td>
// </tr>
// <tr>
// <th>@_loader-icon-background-image</th>
// <td>@loader-icon__background-image</td>
// <td class="vars_value">url('@{baseDir}images/loader-2.gif')</td>
// <td class="vars_value">'' | false | value</td>
// <td>Loader icon ackground image</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_loader-icon-background-position</th>
// <td>@loader-icon__background-position</td>
// <td class="vars_value">50% 50%</td>
// <td class="vars_value">'' | false | value</td>
// <td>Loader icon background position</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_loader-icon-border-radius</th>
// <td>@loader-icon__border-radius</td>
// <td class="vars_value">5px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Loader icon border radius</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_loader-icon-padding</th>
// <td>@loader-icon__padding</td>
// <td class="vars_value">''</td>
// <td class="vars_value">'' | false | value</td>
// <td>Loader icon icon padding</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_loader-text</th>
// <td>@loader-text</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Loader text presence</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_loader-text-color</th>
// <td>@loader-text__color</td>
// <td class="vars_value">@primary__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Loader text color</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_loader-text-font-size</th>
// <td>@loader-text__font-size</td>
// <td class="vars_value">@font-size__base</td>
// <td class="vars_value">'' | false | value</td>
// <td>Loader text font size</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_loader-text-font-family</th>
// <td>@loader-text__font-family</td>
// <td class="vars_value">@font-family__base</td>
// <td class="vars_value">'' | false | value</td>
// <td>Loader text font family</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_loader-text-font-weight</th>
// <td>@loader-text__font-weight</td>
// <td class="vars_value">@font-weight__regular</td>
// <td class="vars_value">'' | false | value</td>
// <td>Loader text font weight</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_loader-text-font-style</th>
// <td>@loader-text__font-style</td>
// <td class="vars_value">@font-style__base</td>
// <td class="vars_value">'' | false | value</td>
// <td>Loader text font style</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_loader-text-padding</th>
// <td>@loader-text__padding</td>
// <td class="vars_value">130px 0 0</td>
// <td class="vars_value">'' | false | value</td>
// <td>Loader text padding</td>
// </tr>
// </table>
// </pre>
//
// # Loading
// Loading is an animation a visitor sees while a certain block is loaded. In this case only this block is locked by an overlay, not the whole page.
//
// ```html
// <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.</p>
// <p id="example2">Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.</p>
// <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.</p>
// <button type="button" onclick="document.getElementById('example2').className='loading';document.getElementById('example2').setAttribute('aria-busy','true');" style="z-index:99999; position: relative;"><span>Show</span></button>
// <button type="button" onclick="document.getElementById('example2').className='';document.getElementById('example2').setAttribute('aria-busy','false');" style="z-index:99999; position: relative;"><span>Hide</span></button>
// ```
.loading {
.lib-loading();
}
// # Loading default variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Global variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_loading-background-color</th>
// <td>@loading__background-color</td>
// <td class="vars_value">@loader-overlay__background-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Loading overlay background color</td>
// </tr>
// <tr>
// <th>@_loading-background-image</th>
// <td>@loading__background-image</td>
// <td class="vars_value">@loader-icon__background-image</td>
// <td class="vars_value">'' | false | value</td>
// <td>Loading overlay background z-index</td>
// </tr>
// </table>
// </pre>
+781
View File
@@ -0,0 +1,781 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
// # Messages
//
// Magento UI library provides mixins for styling messages. There are 4 types of messages:
// ```css
// info
// warning
// error
// success
// ```
// To configure styles of each type of message, global variables from variables.less are used. To apply the <code>.lib-message()</code> mixin you need to specify the type of message you want to apply styles to.
//
// # Information message
//
// This is an informational message. To apply appropriate style you need to specify the <code>info</code> type to the <code>.lib-message()</code> mixin.
//
// If there is no content on the page, for example on a category page with no products, a special system information message with <code>class=”message info empty”</code> is used. It inherits styles from information message by default. It can be styled to get unique appearance using <code>.message.info.empty</code> class.
//
// ```
// <div class="example-message-info">
// <div>
// Lorem ipsum dolor sit <a href="#">amet</a>, consectetuer adipiscing elit. Aenean commodo ligula eget dolor.
// </div>
// </div>
// ```
.example-message-info {
.lib-message(info);
}
// # Warning message
//
// This is a warning message. To apply appropriate style you need to specify <code>warning</code> type to the <code>.warning()</code> mixin.
//
// ```
// <div class="example-message-warning">
// <div>
// Lorem ipsum dolor sit <a href="#">amet</a>, consectetuer adipiscing elit. Aenean commodo ligula eget dolor.
// </div>
// </div>
// ```
.example-message-warning {
.lib-message(warning);
}
// # Error message
//
// This is an error message. To apply appropriate style you need to specify <code>error</code> type to the <code>.warning()</code> mixin.
//
// ```
// <div class="example-message-error">
// <div>
// Lorem ipsum dolor sit <a href="#">amet</a>, consectetuer adipiscing elit. Aenean commodo ligula eget dolor.
// </div>
// </div>
// ```
.example-message-error {
.lib-message(error);
}
// # Success message
//
// This is a success message. To apply appropriate style you need to specify <code>success</code> type to the <code>.warning()</code> mixin.
//
// ```
// <div class="example-message-success">
// <div>
// Lorem ipsum dolor sit <a href="#">amet</a>, consectetuer adipiscing elit. Aenean commodo ligula eget dolor.
// </div>
// </div>
// ```
.example-message-success {
.lib-message(success);
}
// # Notice message
//
// This is a notice message. To apply appropriate style you need to specify <code>notice</code> type to the <code>.warning()</code> mixin.
//
// ```
// <div class="example-message-notice">
// <div>
// Lorem ipsum dolor sit <a href="#">amet</a>, consectetuer adipiscing elit. Aenean commodo ligula eget dolor.
// </div>
// </div>
// ```
.example-message-notice {
.lib-message(notice);
}
// # Message with inner icon
//
// To add an inner icon use <code>.lib-message-icon-inner</code> mixin. To apply the <code>.message-icon-inner</code> mixin, you need to specify the type of a message that you want to apply styles to.
//
// ```html
// <div class="example-message-1">
// <div>
// Lorem ipsum dolor sit <a href="#">amet</a>, consectetuer adipiscing elit. Aenean commodo ligula eget dolor.
// </div>
// </div>
// ```
//
.example-message-1 {
.lib-message-icon-inner(notice);
}
// # Message with lateral icon
//
// To add a lateral icon to a message, you need to use the <code>.lib-message-icon-lateral</code> mixin. This mixin is configured by the following variables:
// ```css
// @_message-type: error; // info | warning | error | success | notice
// @_message-position: right; // left | right
// ```
//
// ```html
// <div class="example-message-2">
// <div>
// Lorem ipsum dolor sit <a href="#">amet</a>, consectetuer adipiscing elit. Aenean commodo ligula eget dolor.
// </div>
// </div>
// ```
// ```html
// <div class="example-message-3">
// <div>
// Lorem ipsum dolor sit <a href="#">amet</a>, consectetuer adipiscing elit. Aenean commodo ligula eget dolor.
// </div>
// </div>
// ```
.example-message-2 {
.lib-message-icon-lateral(error, right);
}
.example-message-3 {
.lib-message-icon-lateral(success, left);
}
// # Custom message style
//
// You can specify your own message type, for example “custom”. To use message mixin for this new type you need to add new variables to _variables.less:
// ```css
// @message__<b>custom</b>-color: #000;
// @message__<b>custom</b>-background: #fc0;
// @message__<b>custom</b>-link-color: blue;
// @message__<b>custom</b>-link-color-hover: darken(@message-custom-link__color, 20%);
// @message__<b>custom</b>-link-color-active: darken(@message-custom-link__color, 30%);
// @message__<b>custom</b>-border-color: orange;
// @message__<b>custom</b>-icon: @icon-settings;
// @message__<b>custom</b>-icon-color: #000;
// @message__<b>custom</b>-icon-background: #green;
// @message__<b>custom</b>-icon-top: 15px;
// @message__<b>custom</b>-icon-right: false;
// @message__<b>custom</b>-icon-bottom: false;
// @message__<b>custom</b>-icon-left: 0;
// ```
// And then call message mixin with your new message type
// ```css
// .lib-message-icon-lateral(custom, left);
// ```
// &nbsp;
// ```html
// <div class="example-message-4">
// <div>
// Lorem ipsum dolor sit <a href="#">amet</a>, consectetuer adipiscing elit. Aenean commodo ligula eget dolor.
// </div>
// </div>
// ```
//
@message-custom__color: @color-black;
@message-custom__background: #fc0;
@message-custom__border-color: orange;
@message-custom-link__color: blue;
@message-custom-link__color-hover: darken(@message-custom-link__color, 20%);
@message-custom-link__color-active: darken(@message-custom-link__color, 30%);
@message-custom-icon: @icon-settings;
@message-custom-icon__color-lateral: @color-black;
@message-custom-icon__background: #green;
@message-custom-icon__top: 15px;
@message-custom-icon__right: false;
@message-custom-icon__bottom: false;
@message-custom-icon__left: 0;
.example-message-4 {
.lib-message-icon-lateral(custom, left);
border-width: 4px;
border-radius: 10px;
}
// # Messages global variables
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@message__padding</th>
// <td class="vars_value">@indent__s @indent__base</td>
// <td class="vars_value">'' | value</td>
// <td>Message padding</td>
// </tr>
// <tr>
// <th>@message__margin</th>
// <td class="vars_value">@indent__xs 0</td>
// <td class="vars_value">'' | value</td>
// <td>Message margin</td>
// </tr>
// <tr>
// <th>@message__color</th>
// <td class="vars_value">false</td>
// <td class="vars_value">true | false</td>
// <td>Each message type has its own message color</td>
// </tr>
// <tr>
// <th colspan="4" class="vars_section">Messages font style</th>
// </tr>
// <tr>
// <th>@message__font-size</th>
// <td class="vars_value">13px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message font size</td>
// </tr>
// <tr>
// <th>@message__font-family</th>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message font family</td>
// </tr>
// <tr>
// <th>@message__font-style</th>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message font style</td>
// </tr>
// <tr>
// <th>@message__font-weight</th>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message font weight</td>
// </tr>
// <tr>
// <th>@message__line-height</th>
// <td class="vars_value">1.2em</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message line height</td>
// </tr>
// <tr>
// <th colspan="4" class="vars_section">Message icon setup</th>
// </tr>
// <tr>
// <th>@message-icon__font-size</th>
// <td class="vars_value">ceil(@message__font-size * 2 + 2)</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon font size</td>
// </tr>
// <tr>
// <th>@message-icon__font-line-height</th>
// <td class="vars_value">@message-icon__font-size</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon line height</td>
// </tr>
// <tr>
// <th>@message-icon__inner-padding-left</th>
// <td class="vars_value">40px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon padding left</td>
// </tr>
// <tr>
// <th>@message-icon__lateral-width</th>
// <td class="vars_value">30px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon lateral width</td>
// </tr>
// <tr>
// <th>@message-icon__lateral-arrow-size</th>
// <td class="vars_value">5px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon arrow size</td>
// </tr>
// <tr>
// <th>@message-icon__top</th>
// <td class="vars_value">18px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon top position</td>
// </tr>
// <tr>
// <th>@message-icon__right</th>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon right position</td>
// </tr>
// <tr>
// <th>@message-icon__bottom</th>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon bottom position</td>
// </tr>
// <tr>
// <th>@message-icon__left</th>
// <td class="vars_value">0</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon left position</td>
// </tr>
// <tr>
// <th colspan="4" class="vars_section">Message border</th>
// </tr>
// <tr>
// <th>@message__border-width</th>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message border width</td>
// </tr>
// <tr>
// <th>@message__border-color</th>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message border color</td>
// </tr>
// <tr>
// <th>@message__border-style</th>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message border style</td>
// </tr>
// <tr>
// <th>@message__border-radius</th>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message border radius</td>
// </tr>
// <tr>
// <th colspan="4" class="vars_section">Information message</th>
// </tr>
// <tr>
// <th>@message-info__color</th>
// <td class="vars_value">#6f4400</td>
// <td class="vars_value">'' | false | value</td>
// <td>Information message text color</td>
// </tr>
// <tr>
// <th>@message-info__background</th>
// <td class="vars_value">#fdf0d5</td>
// <td class="vars_value">'' | false | value</td>
// <td>Information message background</td>
// </tr>
// <tr>
// <th>@message-info-link__color</th>
// <td class="vars_value">@link__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Information message link color</td>
// </tr>
// <tr>
// <th>@message-info-link__color-hover</th>
// <td class="vars_value">@link__hover__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Information message hovered link color</td>
// </tr>
// <tr>
// <th>@message-info-link__color-active</th>
// <td class="vars_value">@link__hover__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Information message active link color </td>
// </tr>
// <tr>
// <th>@message-info__border-color</th>
// <td class="vars_value">@message__border-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Information message border color</td>
// </tr>
// <tr>
// <th>@message-info-icon</th>
// <td class="vars_value">@icon-warning</td>
// <td class="vars_value">'' | false | value</td>
// <td>Information message icon symbol code</td>
// </tr>
// <tr>
// <th>@message-info-icon__color-inner</th>
// <td class="vars_value">#c07600</td>
// <td class="vars_value">'' | false | value</td>
// <td>Information message icon symbol color </td>
// </tr>
// <tr>
// <th>@message-info-icon__color-lateral</th>
// <td class="vars_value">@color-white</td>
// <td class="vars_value">'' | false | value</td>
// <td>Information message lateral icon symbol color</td>
// </tr>
// <tr>
// <th>@message-info-icon__background</th>
// <td class="vars_value">#6f4400</td>
// <td class="vars_value">'' | false | value</td>
// <td>Information message icon background</td>
// </tr>
// <tr>
// <th>@message-info-icon__top</th>
// <td class="vars_value">@message-icon__top</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon top position</td>
// </tr>
// <tr>
// <th>@message-info-icon__right</th>
// <td class="vars_value">@message-icon__right</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon right position</td>
// </tr>
// <tr>
// <th>@message-info-icon__bottom</th>
// <td class="vars_value">@message-icon__bottom</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon bottom position</td>
// </tr>
// <tr>
// <th>@message-info-icon__left</th>
// <td class="vars_value">@message-icon__left</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon left position</td>
// </tr>
// <tr>
// <th colspan="4" class="vars_section">Warning message</th>
// </tr>
// <tr>
// <th>@message-warning__color</th>
// <td class="vars_value">@message-info__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Warning message text color</td>
// </tr>
// <tr>
// <th>@message-warning__background</th>
// <td class="vars_value">@message-info__background</td>
// <td class="vars_value">'' | false | value</td>
// <td>Warning message background</td>
// </tr>
// <tr>
// <th>@message-warning-link__color</th>
// <td class="vars_value">@message-info-link__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Warning message link color</td>
// </tr>
// <tr>
// <th>@message-warning-link__color-hover</th>
// <td class="vars_value">@message-info-link__color-hover</td>
// <td class="vars_value">'' | false | value</td>
// <td>Warning message hovered link color</td>
// </tr>
// <tr>
// <th>@message-warning-link__color-active</th>
// <td class="vars_value">@message-info-link__color-active</td>
// <td class="vars_value">'' | false | value</td>
// <td>Warning message active link color </td>
// </tr>
// <tr>
// <th>@message-info__border-color</th>
// <td class="vars_value">@message-info__border-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Warning message border color</td>
// </tr>
// <tr>
// <th>@message-warning-icon</th>
// <td class="vars_value">@message-info-icon</td>
// <td class="vars_value">'' | false | value</td>
// <td>Warning message icon symbol code</td>
// </tr>
// <tr>
// <th>@message-warning-icon__color-inner</th>
// <td class="vars_value">@message-info-icon__color-inner</td>
// <td class="vars_value">'' | false | value</td>
// <td>Warning message icon symbol color </td>
// </tr>
// <tr>
// <th nowrap="nowrap">@message-warning-icon__color-lateral</th>
// <td class="vars_value" nowrap="nowrap">@message-info-icon__color-lateral</td>
// <td class="vars_value">'' | false | value</td>
// <td>Warning message lateral icon symbol color</td>
// </tr>
// <tr>
// <th>@message-warning-icon__background</th>
// <td class="vars_value">@message-info-icon__background</td>
// <td class="vars_value">'' | false | value</td>
// <td>Warning message icon background</td>
// </tr>
// <tr>
// <th>@message-warning-icon__top</th>
// <td class="vars_value">@message-icon__top</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon top position</td>
// </tr>
// <tr>
// <th>@message-warning-icon__right</th>
// <td class="vars_value">@message-icon__right</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon right position</td>
// </tr>
// <tr>
// <th>@message-warning-icon__bottom</th>
// <td class="vars_value">@message-icon__bottom</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon bottom position</td>
// </tr>
// <tr>
// <th>@message-warning-icon__left</th>
// <td class="vars_value">@message-icon__left</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon left position</td>
// </tr>
// <tr>
// <th colspan="4" class="vars_section">Error message</th>
// </tr>
// <tr>
// <th>@message-error__color</th>
// <td class="vars_value">@error__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Error message text color</td>
// </tr>
// <tr>
// <th>@message-error__background</th>
// <td class="vars_value">#fae5e5</td>
// <td class="vars_value">'' | false | value</td>
// <td>Error message background</td>
// </tr>
// <tr>
// <th>@message-error-link__color</th>
// <td class="vars_value">@link__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Error message link color</td>
// </tr>
// <tr>
// <th>@message-error-link__color-hover</th>
// <td class="vars_value">@link__hover__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Error message hovered link color</td>
// </tr>
// <tr>
// <th>@message-error-link__color-active</th>
// <td class="vars_value">@link__hover__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Error message active link color </td>
// </tr>
// <tr>
// <th>@message-error__border-color</th>
// <td class="vars_value">@message__border-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Error message border color</td>
// </tr>
// <tr>
// <th>@message-error-icon</th>
// <td class="vars_value">@icon-warning</td>
// <td class="vars_value">'' | false | value</td>
// <td>Error message icon symbol code</td>
// </tr>
// <tr>
// <th>@message-error-icon__color-inner</th>
// <td class="vars_value">#b30000</td>
// <td class="vars_value">'' | false | value</td>
// <td>Error message icon symbol color </td>
// </tr>
// <tr>
// <th>@message-error-icon__color-lateral</th>
// <td class="vars_value">@color-white</td>
// <td class="vars_value">'' | false | value</td>
// <td>Error message lateral icon symbol color</td>
// </tr>
// <tr>
// <th>@message-error-icon__background</th>
// <td class="vars_value">#b30000</td>
// <td class="vars_value">'' | false | value</td>
// <td>Error message icon background</td>
// </tr>
// <tr>
// <th>@message-error-icon__top</th>
// <td class="vars_value">@message-icon__top</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon top position</td>
// </tr>
// <tr>
// <th>@message-error-icon__right</th>
// <td class="vars_value">@message-icon__right</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon right position</td>
// </tr>
// <tr>
// <th>@message-error-icon__bottom</th>
// <td class="vars_value">@message-icon__bottom</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon bottom position</td>
// </tr>
// <tr>
// <th>@message-error-icon__left</th>
// <td class="vars_value">@message-icon__left</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon left position</td>
// </tr>
// <tr>
// <th colspan="4" class="vars_section">Success message</th>
// </tr>
// <tr>
// <th>@message-success__color</th>
// <td class="vars_value">#006400</td>
// <td class="vars_value">'' | false | value</td>
// <td>Success message text color</td>
// </tr>
// <tr>
// <th>@message-success__background</th>
// <td class="vars_value">#e5efe5</td>
// <td class="vars_value">'' | false | value</td>
// <td>Success message background</td>
// </tr>
// <tr>
// <th>@message-success-link__color</th>
// <td class="vars_value">@link__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Success message link color</td>
// </tr>
// <tr>
// <th>@message-success-link__color-hover</th>
// <td class="vars_value">@link__hover__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Success message hovered link color</td>
// </tr>
// <tr>
// <th>@message-success-link__color-active</th>
// <td class="vars_value">@link__hover__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Success message active link color </td>
// </tr>
// <tr>
// <th>@message-success__border-color</th>
// <td class="vars_value">@message__border-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Success message border color</td>
// </tr>
// <tr>
// <th>@message-success-icon</th>
// <td class="vars_value">@icon-checkmark</td>
// <td class="vars_value">'' | false | value</td>
// <td>Success message icon symbol code</td>
// </tr>
// <tr>
// <th>@message-success-icon__color-inner</th>
// <td class="vars_value">#006400</td>
// <td class="vars_value">'' | false | value</td>
// <td>Success message icon symbol color </td>
// </tr>
// <tr>
// <th>@message-success-icon__color-lateral</th>
// <td class="vars_value">@color-white</td>
// <td class="vars_value">'' | false | value</td>
// <td>Success message lateral icon symbol color</td>
// </tr>
// <tr>
// <th>@message-success-icon__background</th>
// <td class="vars_value">#006400</td>
// <td class="vars_value">'' | false | value</td>
// <td>Success message icon background</td>
// </tr>
// <tr>
// <th>@message-success-icon__top</th>
// <td class="vars_value">@message-icon__top</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon top position</td>
// </tr>
// <tr>
// <th>@message-success-icon__right</th>
// <td class="vars_value">@message-icon__right</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon right position</td>
// </tr>
// <tr>
// <th>@message-success-icon__bottom</th>
// <td class="vars_value">@message-icon__bottom</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon bottom position</td>
// </tr>
// <tr>
// <th>@message-success-icon__left</th>
// <td class="vars_value">@message-icon__left</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon left position</td>
// </tr>
// <tr>
// <th colspan="4" class="vars_section">Notice message</th>
// </tr>
// <tr>
// <th>@message-notice__color</th>
// <td class="vars_value">@message-info__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Notice message text color</td>
// </tr>
// <tr>
// <th>@message-notice__background</th>
// <td class="vars_value">@message-info__background</td>
// <td class="vars_value">'' | false | value</td>
// <td>Notice message background</td>
// </tr>
// <tr>
// <th>@message-notice-link__color</th>
// <td class="vars_value">@message-info-link__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Notice message link color</td>
// </tr>
// <tr>
// <th>@message-notice-link__color-hover</th>
// <td class="vars_value">@message-info-link__color-hover</td>
// <td class="vars_value">'' | false | value</td>
// <td>Notice message hovered link color</td>
// </tr>
// <tr>
// <th>@message-notice-link__color-active</th>
// <td class="vars_value">@message-info-link__color-active</td>
// <td class="vars_value">'' | false | value</td>
// <td>Notice message active link color </td>
// </tr>
// <tr>
// <th>@message-notice__border-color</th>
// <td class="vars_value">@message-info__border-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Notice message border color</td>
// </tr>
// <tr>
// <th>@message-notice-icon</th>
// <td class="vars_value">@message-info-icon</td>
// <td class="vars_value">'' | false | value</td>
// <td>Notice message icon symbol code</td>
// </tr>
// <tr>
// <th>@message-notice-icon__color-inner</th>
// <td class="vars_value">@message-info-icon__color-inner</td>
// <td class="vars_value">'' | false | value</td>
// <td>Notice message icon symbol color </td>
// </tr>
// <tr>
// <th>@message-notice-icon__color-lateral</th>
// <td class="vars_value">@message-info-icon__color-lateral</td>
// <td class="vars_value">'' | false | value</td>
// <td>Notice message lateral icon symbol color</td>
// </tr>
// <tr>
// <th>@message-notice-icon__background</th>
// <td class="vars_value">@message-info-icon__background</td>
// <td class="vars_value">'' | false | value</td>
// <td>Notice message icon background</td>
// </tr>
// <tr>
// <th>@message-notice-icon__top</th>
// <td class="vars_value">@message-icon__top</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon top position</td>
// </tr>
// <tr>
// <th>@message-notice-icon__right</th>
// <td class="vars_value">@message-icon__right</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon right position</td>
// </tr>
// <tr>
// <th>@message-notice-icon__bottom</th>
// <td class="vars_value">@message-icon__bottom</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon bottom position</td>
// </tr>
// <tr>
// <th>@message-notice-icon__left</th>
// <td class="vars_value">@message-icon__left</td>
// <td class="vars_value">'' | false | value</td>
// <td>Message icon left position</td>
// </tr>
// </table>
// </pre>
+873
View File
@@ -0,0 +1,873 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
// # Pagination HTML markup
// Pagination is used to display numbers of pages in case content exceeds page limits. The markup corresponds to accessibility demands.
//
// Required HTML markup:
// ```html
// <div class="pages">
// <strong class="label" id="paging-label">Page</strong>
// <ul class="items" aria-labelledby="paging-label">
// <li class="item">
// <a href="1" class="action previous">
// <span class="label">Page</span>
// <span>Previous</span>
// </a>
// </li>
// <li class="item">
// <a href="1" class="page">
// <span class="label">Page</span>
// <span>1</span>
// </a>
// </li>
// <li class="item current">
// <strong class="page">
// <span class="label">You're currently reading page</span>
// <span>2</span>
// </strong>
// </li>
// <li class="item">
// <a href="1" class="page">
// <span class="label">Page</span>
// <span>3</span>
// </a>
// </li>
// <li class="item">
// <a href="1" class="action next">
// <span class="label">Page</span>
// <span>Next</span>
// </a>
// </li>
// </ul>
// </div>
// ```
.pages {
.lib-pager();
}
// # Pagination variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Global variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th nowrap="nowrap">@_pager-label-display</th>
// <td>@pager-label__display</td>
// <td class="vars_value">none</td>
// <td class="vars_value">none | block | inline-block</td>
// <td>The 'page' label is displayed</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_pager-item-display</th>
// <td>@pager-item__display</td>
// <td class="vars_value">inline-block</td>
// <td class="vars_value">none | block | inline-block</td>
// <td>The pager item label is displayed</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_pager-reset-spaces</th>
// <td>@pager-reset-spaces</td>
// <td class="vars_value">true</td>
// <td class="vars_value">true | false</td>
// <td>Reset spaces between inline-block elements if elements 'display' is set to 'inline-block'</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_pager-font-size</th>
// <td>@pager__font-size</td>
// <td class="vars_value">@font-size__s</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager font size</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_pager-font-weight</th>
// <td>@pager__font-weight</td>
// <td class="vars_value">@font-weight__bold</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager font weight</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_pager-line-height</th>
// <td>@pager__line-height</td>
// <td class="vars_value">32px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager line height</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_pager-item-margin</th>
// <td>@pager-item__margin</td>
// <td class="vars_value">0 2px 0 0</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item margin</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_pager-item-padding</th>
// <td>@pager-item__padding</td>
// <td class="vars_value">0 4px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item padding</td>
// </tr>
// <tr>
// <th>@_pager-actions-padding</th>
// <td>@pager-actions__padding</td>
// <td class="vars_value">0</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager actions padding</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Pager current page</th>
// </tr>
// <tr>
// <th>@_pager-current-font-weight</th>
// <td>@pager-current__font-weight</td>
// <td class="vars_value">@font-weight__bold;</td>
// <td class="vars_value">'' | false | value</td>
// <td>Current page number font weight</td>
// </tr>
// <tr>
// <th>@_pager-current-color</th>
// <td>@pager-current__color</td>
// <td class="vars_value">@primary__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Current page number color</td>
// </tr>
// <tr>
// <th>@_pager-current-border</th>
// <td>@pager-current__border</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Current page number border</td>
// </tr>
// <tr>
// <th>@_pager-current-background</th>
// <td>@pager-current__background</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Current page number background</td>
// </tr>
// <tr>
// <th>@_pager-current-gradient</th>
// <td>@pager-current__gradient</td>
// <td class="vars_value">false</td>
// <td class="vars_value">true | false</td>
// <td>Current page number has gradient background</td>
// </tr>
// <tr>
// <th>@_pager-current-gradient-direction</th>
// <td>@pager-current__gradient-direction</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | vertical | horizontal</td>
// <td>Direction of current page number background gradient (if there is any)</td>
// </tr>
// <tr>
// <th>@_pager-current-gradient-color-start</th>
// <td>@pager-current__gradient-color-start</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Current page number gradient start color</td>
// </tr>
// <tr>
// <th>@_pager-current-gradient-color-end</th>
// <td>@pager-current__gradient-color-end</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Current page number gradient end color</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Link to page number</th>
// </tr>
// <tr>
// <th>@_pager-gradient</th>
// <td>@pager__gradient</td>
// <td class="vars_value">false</td>
// <td class="vars_value">true | false</td>
// <td>Pager items have gradient background</td>
// </tr>
// <tr>
// <th>@_pager-gradient-direction</th>
// <td>@pager__gradient-direction</td>
// <td class="vars_value">'false</td>
// <td class="vars_value">'' | false | vertical | horizontal</td>
// <td>Direction of background gradient (if there is any) of pager item</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Link to page number - default</th>
// </tr>
// <tr>
// <th>@_pager-color</th>
// <td>@pager__color</td>
// <td class="vars_value">@link__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item color</td>
// </tr>
// <tr>
// <th>@_pager-border</th>
// <td>@pager__border</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item border</td>
// </tr>
// <tr>
// <th>@_pager-text-decoration</th>
// <td>@pager__text-decoration</td>
// <td class="vars_value">none</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item text decoration</td>
// </tr>
// <tr>
// <th>@_pager-background</th>
// <td>@pager__background</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item background</td>
// </tr>
// <tr>
// <th>@_pager-gradient-color-start</th>
// <td>@pager__gradient-color-start</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item gradient start color</td>
// </tr>
// <tr>
// <th>@_pager-gradient-color-end</th>
// <td>@pager__gradient-color-end</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item gradient end color</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Link to page number - visited</th>
// </tr>
// <tr>
// <th>@_pager-color-visited</th>
// <td>@pager__visited__color</td>
// <td class="vars_value">@link__visited__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item visited color</td>
// </tr>
// <tr>
// <th>@_pager-border-visited</th>
// <td>@pager__visited__border</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item visited border</td>
// </tr>
// <tr>
// <th>@_pager-background-visited</th>
// <td>@pager__visited__background</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item visited background</td>
// </tr>
// <tr>
// <th>@_pager-gradient-color-start-visited</th>
// <td>@pager__visited__gradient-color-start</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item visited gradient start color</td>
// </tr>
// <tr>
// <th>@_pager-gradient-color-end-visited</th>
// <td>@pager__visited__gradient-color-end</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item visited gradient end color</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Link to page number - hover</th>
// </tr>
// <tr>
// <th>@_pager-color-hover</th>
// <td>@pager__hover__color</td>
// <td class="vars_value">@link__hover__color</td>
// <td class="vars_value">&nbsp;</td>
// <td>Pager item hover color</td>
// </tr>
// <tr>
// <th>@_pager-border-hover</th>
// <td>@pager__hover__border</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item hover border</td>
// </tr>
// <tr>
// <th>@_pager-text-decoration-hover</th>
// <td>@pager__text-decoration</td>
// <td class="vars_value">none</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item hover text decoration</td>
// </tr>
// <tr>
// <th>@_pager-background-hover</th>
// <td>@pager__hover__background</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item hover background</td>
// </tr>
// <tr>
// <th>@_pager-gradient-color-start-hover</th>
// <td>@pager__hover__gradient-color-start</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item hover gradient start color</td>
// </tr>
// <tr>
// <th>@_pager-gradient-color-end-hover</th>
// <td>@pager__hover__gradient-color-end</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item hover gradient end color</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Link to page number - active</th>
// </tr>
// <tr>
// <th>@_pager-color-active</th>
// <td>@pager__active__color</td>
// <td class="vars_value">@link__hover__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item active color</td>
// </tr>
// <tr>
// <th>@_pager-border-active</th>
// <td>@pager__active__border</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item active border</td>
// </tr>
// <tr>
// <th>@_pager-background-active</th>
// <td>@pager__active__background</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item active background</td>
// </tr>
// <tr>
// <th>@_pager-gradient-color-start-active</th>
// <td>@pager__active__gradient-color-start</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item active gradient start color</td>
// </tr>
// <tr>
// <th>@_pager-gradient-color-end-active</th>
// <td>@pager__active__gradient-color-end</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager item active gradient end color</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Previous/next action links - icons</th>
// </tr>
// <tr>
// <th>@_pager-icon-use</th>
// <td>@pager-icon__use</td>
// <td class="vars_value">true</td>
// <td class="vars_value">true | false</td>
// <td>previous/next links have icons</td>
// </tr>
// <tr>
// <th>@_pager-icon-previous-content</th>
// <td>@pager-icon__previous-content</td>
// <td class="vars_value">@icon-prev</td>
// <td class="vars_value">'' | false | value</td>
// <td>&quot;previous&quot; link icon</td>
// </tr>
// <tr>
// <th>@_pager-icon-next-content</th>
// <td>@pager-icon__next-content</td>
// <td class="vars_value">@icon-next</td>
// <td class="vars_value">'' | false | value</td>
// <td>&quot;next&quot; link icon</td>
// </tr>
// <tr>
// <th>@_pager-icon-font-text-hide</th>
// <td>@pager-icon__text-hide</td>
// <td class="vars_value">true</td>
// <td class="vars_value">true | false</td>
// <td>The &quot;previous&quot; and &quot;next&quot; words are hidden</td>
// </tr>
// <tr>
// <th>@_pager-icon-font-position</th>
// <td>@pager-icon__position</td>
// <td class="vars_value">before</td>
// <td class="vars_value">before | after</td>
// <td>Icon position</td>
// </tr>
// <tr>
// <th>@_pager-icon-font</th>
// <td>@pager-icon__font</td>
// <td class="vars_value">@icon-font</td>
// <td class="vars_value">'' | false | value</td>
// <td>Icon font</td>
// </tr>
// <tr>
// <th>@_pager-icon-font-margin</th>
// <td>@pager-icon__font-margin</td>
// <td class="vars_value">0 0 0 -6px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Icon font margin</td>
// </tr>
// <tr>
// <th>@_pager-icon-font-vertical-align</th>
// <td>@pager-icon__font-vertical-align</td>
// <td class="vars_value">top</td>
// <td class="vars_value">'' | false | value</td>
// <td>Icon font vertical align</td>
// </tr>
// <tr>
// <th>@_pager-icon-font-size</th>
// <td>@pager-icon__font-size</td>
// <td class="vars_value">46px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Icon font size</td>
// </tr>
// <tr>
// <th>@_pager-icon-font-line-height</th>
// <td>@pager-icon__font-line-height</td>
// <td class="vars_value">@icon-font__line-height</td>
// <td class="vars_value">'' | false | value</td>
// <td>Icon font line height</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Previous/next action links</th>
// </tr>
// <tr>
// <th>@_pager-action-gradient</th>
// <td>@pager__gradient</td>
// <td class="vars_value">false</td>
// <td class="vars_value">true | false</td>
// <td>Previous/next links have gradient background</td>
// </tr>
// <tr>
// <th>@_pager-action-gradient-direction</th>
// <td>@pager__gradient-direction</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | vertical | horizontal</td>
// <td>Direction of background gradient (if there is any) of previous/next links</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Previous/next action links - default</th>
// </tr>
// <tr>
// <th>@_pager-action-color</th>
// <td>@pager-action__color</td>
// <td class="vars_value">@text__color__muted</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action color</td>
// </tr>
// <tr>
// <th>@_pager-action-border</th>
// <td>@pager-action__border</td>
// <td class="vars_value">@border-width__base solid @border-color__base</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action border</td>
// </tr>
// <tr>
// <th>@_pager-action-text-decoration</th>
// <td>@pager-action__text-decoration</td>
// <td class="vars_value">@pager__text-decoration</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action text decoration</td>
// </tr>
// <tr>
// <th>@_pager-action-background</th>
// <td>@pager-action__background</td>
// <td class="vars_value">@pager__background</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action background</td>
// </tr>
// <tr>
// <th>@_pager-action-gradient-color-start</th>
// <td>@pager__gradient-color-start</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action gradient start color</td>
// </tr>
// <tr>
// <th>@_pager-action-gradient-color-end</th>
// <td>@pager__gradient-color-end</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action gradient end color</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Previous/next action links - visited</th>
// </tr>
// <tr>
// <th>@_pager-action-color-visited</th>
// <td>@pager-action__visited__color</td>
// <td class="vars_value">@pager-action__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action visited color</td>
// </tr>
// <tr>
// <th>@_pager-action-border-visited</th>
// <td>@pager-action__visited__border</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action visited border</td>
// </tr>
// <tr>
// <th>@_pager-action-background-visited</th>
// <td>@pager-action__visited__background</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action visited background</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_pager-action-gradient-color-start-visited</th>
// <td>@pager__visited__gradient-color-start</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action visited gradient start color</td>
// </tr>
// <tr>
// <th>@_pager-action-gradient-color-end-visited</th>
// <td>@pager__visited__gradient-color-end</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action visited gradient end color</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Previous/next action links - hover</th>
// </tr>
// <tr>
// <th>@_pager-action-color-hover</th>
// <td>@pager-action__hover__color</td>
// <td class="vars_value">@pager-action__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action hover color</td>
// </tr>
// <tr>
// <th>@_pager-action-border-hover</th>
// <td>@pager-action__hover__border</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action hover border</td>
// </tr>
// <tr>
// <th>@_pager-action-text-decoration-hover</th>
// <td>@pager-action__hover__text-decoration</td>
// <td class="vars_value" nowrap="nowrap">@pager__hover__text-decoration</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action hover text decoration</td>
// </tr>
// <tr>
// <th>@_pager-action-background-hover</th>
// <td>@pager-action__hover__background</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action hover background</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_pager-action-gradient-color-start-hover</th>
// <td>@pager__hover__gradient-color-start</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action hover gradient start color</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_pager-action-gradient-color-end-hover</th>
// <td>@pager__hover__gradient-color-end</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action hover gradient end color</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Previous/next action links - active</th>
// </tr>
// <tr>
// <th>@_pager-action-color-active</th>
// <td>@pager-action__active__color</td>
// <td class="vars_value">@pager-action__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action active color</td>
// </tr>
// <tr>
// <th>@_pager-action-border-active</th>
// <td>@pager-action__active__border</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action active border</td>
// </tr>
// <tr>
// <th>@_pager-action-background-active</th>
// <td>@pager-action__active__background</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action active background</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_pager-action-gradient-color-start-active</th>
// <td>@pager__active__gradient-color-start</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action active gradient start color</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_pager-action-gradient-color-end-active</th>
// <td>@pager__active__gradient-color-end</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Pager action active gradient end color</td>
// </tr>
// </table>
// </pre>
// # Pagination with label and gradient background on links
//
// To display label set:
// ```css
// @_pager-label-display: inline-block
// ```
// To set up gradient background on pages numbers use:
// ```css
// @_pager-gradient: true
// ```
// To set gradient start and end colors for default and hovered link states use:
// ```css
// @_pager-gradient-color-start: #f4f4f4
// @_pager-gradient-color-end: #ccc
// @_pager-gradient-color-start-hover: #ccc
// @_pager-gradient-color-end-hover: #f4f4f4
// ```
// To set an icon on "previous" and "next" links use:
// ```css
// @_pager-icon-use: true
// @_pager-icon-previous-content: @icon-prev
// @_pager-icon-next-content: @icon-next
// ```
// ```html
// <div class="example-pages-1">
// <strong class="label" id="paging-label">Page</strong>
// <ul class="items" aria-labelledby="paging-label">
// <li class="item">
// <a href="1" class="action previous">
// <span class="label">Page</span>
// <span>Previous</span>
// </a>
// </li>
// <li class="item">
// <a href="1" class="page">
// <span class="label">Page</span>
// <span>1</span>
// </a>
// </li>
// <li class="item current">
// <strong class="page">
// <span class="label">You're currently reading page</span>
// <span>2</span>
// </strong>
// </li>
// <li class="item">
// <a href="1" class="page">
// <span class="label">Page</span>
// <span>3</span>
// </a>
// </li>
// <li class="item">
// <a href="1" class="action next">
// <span class="label">Page</span>
// <span>Next</span>
// </a>
// </li>
// </ul>
// </div>
// ```
.example-pages-1 {
.lib-pager(
@_pager-font-size: 12px,
@_pager-label-display: inline-block,
@_pager-item-margin: 0 3px,
@_pager-gradient: true,
@_pager-gradient-direction: vertical,
@_pager-color: #333,
@_pager-gradient-color-start: #f4f4f4,
@_pager-gradient-color-end: #ccc,
@_pager-border: 1px solid darken(#ccc, 10%),
@_pager-color-hover: #333,
@_pager-gradient-color-start-hover: #ccc,
@_pager-gradient-color-end-hover: #f4f4f4,
@_pager-border-hover: 1px solid darken(#ccc, 20%),
@_pager-action-gradient: false,
@_pager-current-color: #f7b32e,
@_pager-current-border: 1px solid darken(#1979c3, 10%),
@_pager-current-background: #1979c3,
@_pager-icon-use: true,
@_pager-icon-previous-content: @icon-prev,
@_pager-icon-next-content: @icon-next,
@_pager-icon-font-size: 30px,
@_pager-action-color-hover: #ff5501
);
}
// # Pagination with "previous"..."next" text links and label
//
// Text view of pagination without borders, backgrounds and icons
//
// Disable icon use for "previous" and "next" links
// ```css
// @_pager-icon-use: false
// ```
// Display pager label
// ```css
// @_pager-label-display: inline-block
// ```
// ```html
// <div class="example-pages-2">
// <strong class="label" id="paging-label">Page</strong>
// <ul class="items" aria-labelledby="paging-label">
// <li class="item">
// <a href="1" class="action previous">
// <span class="label">Page</span>
// <span>Previous</span>
// </a>
// </li>
// <li class="item">
// <a href="1" class="page">
// <span class="label">Page</span>
// <span>1</span>
// </a>
// </li>
// <li class="item current">
// <strong class="page">
// <span class="label">You're currently reading page</span>
// <span>2</span>
// </strong>
// </li>
// <li class="item">
// <a href="1" class="page">
// <span class="label">Page</span>
// <span>3</span>
// </a>
// </li>
// <li class="item">
// <a href="1" class="action next">
// <span class="label">Page</span>
// <span>Next</span>
// </a>
// </li>
// </ul>
// </div>
// ```
.example-pages-2 {
.lib-pager(
@_pager-label-display: inline-block,
@_pager-icon-use: false
);
}
// # Pagination without label, with solid background
//
// Pagination without label, with solid background and icons on previous/next links
//
// Hide pager label:
// ```css
// @_pager-label-display: none
// ```
// To set background and font colors for default, visited, hover, active states, use:
// ```css
// @_pager-color: #fff,
// @_pager-background: @link__color,
// @_pager-color-visited: #fff,
// @_pager-background-visited: @link__visited__color,
// @_pager-color-hover: #fff,
// @_pager-background-hover: @link__hover__color,
// @_pager-color-active: #fff,
// @_pager-background-active: @link__active__color,
// @_pager-current-color: #fff,
// @_pager-current-background: @link__visited__color,
// @_pager-action-background: @link__color,
// @_pager-icon-font-color: #fff,
// @_pager-action-background-visited: @link__visited__color
// ```
// To set current page background and font color, use:
// ```css
// @_pager-current-color: #fff,
// @_pager-current-background: @link__visited__color
// ```
// To set background and icon color for default, visited, hover, active states of "previous" and "next" links, use:
// ```css
// @_pager-action-background: @link__color,
// @_pager-action-background-visited: @link__visited__color,
// @_pager-action-background-hover: @link__hover__color,
// @_pager-action-background-active: @link__active__color,
//
// @_pager-icon-font-color: #fff,
// @_pager-icon-font-color-visited: #fff,
// @_pager-icon-font-color-hover: #fff,
// @_pager-icon-font-color-active: #fff
// ```
//
// ```html
// <div class="example-pages-3">
// <strong class="label" id="paging-label">Page</strong>
// <ul class="items" aria-labelledby="paging-label">
// <li class="item">
// <a href="1" class="action previous">
// <span class="label">Page</span>
// <span>Previous</span>
// </a>
// </li>
// <li class="item">
// <a href="1" class="page">
// <span class="label">Page</span>
// <span>1</span>
// </a>
// </li>
// <li class="item current">
// <strong class="page">
// <span class="label">You're currently reading page</span>
// <span>2</span>
// </strong>
// </li>
// <li class="item">
// <a href="1" class="page">
// <span class="label">Page</span>
// <span>3</span>
// </a>
// </li>
// <li class="item">
// <a href="1" class="action next">
// <span class="label">Page</span>
// <span>Next</span>
// </a>
// </li>
// </ul>
// </div>
// ```
.example-pages-3 {
.lib-pager(
@_pager-label-display: none,
@_pager-color: @color-white,
@_pager-background: @link__color,
@_pager-color-visited: @color-white,
@_pager-background-visited: @link__visited__color,
@_pager-color-hover: @color-white,
@_pager-background-hover: @link__hover__color,
@_pager-color-active: @color-white,
@_pager-background-active: @link__active__color,
@_pager-current-color: @color-white,
@_pager-current-background: @link__visited__color,
@_pager-action-background: @link__color,
@_pager-action-background-visited: @link__visited__color,
@_pager-action-background-hover: @link__hover__color,
@_pager-action-background-active: @link__active__color,
@_pager-action-color: @color-white,
@_pager-action-color-hover: @color-white,
@_pager-action-color-active: @color-white
);
}
+824
View File
@@ -0,0 +1,824 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
// # Popups
// To implement the popup, use the following markup. It corresponds accessibility requirements. To set Popup styles use the <code>.lib-popup()</code> mixin.
//
// The <code>.lib-window-overlay()</code> mixin controls the styles of overlay background.
// ##Simple popup
//
// ``` html
// <button type="button" class="action toggle" data-toggle="popup" data-backdrop="true" data-target="#window-popup" aria-expanded="false" aria-controls="window-popup"><span>Show popup</span></button>
// <div class="window popup popup-example" id="window-popup" tabindex="-1" role="dialog" aria-labelledby="popup-title" aria-describedby="popup-content" aria-hidden="true">
// <div class="popup actions">
// <div class="secondary">
// <button type="button" class="action close" data-dismiss="popup"><span>Close</span></button>
// </div>
// </div>
// <div class="popup header">
// <strong class="title" id="popup-title"><span>Popup title</span></strong>
// </div>
// <div class="popup content" id="popup-content">
// <p>Popup content</p>
// </div>
// <div class="popup footer"></div>
// </div>
// ```
//
// ##Popup with actions toolbar
//
// ``` html
// <button type="button" class="action toggle" data-toggle="popup" data-backdrop="true" data-target="#window-popup" aria-expanded="false" aria-controls="window-popup"><span>Show popup</span></button>
// <div class="window popup popup-example-1" id="window-popup" tabindex="-1" role="dialog" aria-labelledby="popup-title" aria-describedby="popup-content" aria-hidden="true">
// <div class="popup actions">
// <div class="secondary">
// <button type="button" class="action close" data-dismiss="popup"><span>Close</span></button>
// </div>
// </div>
// <div class="popup header">
// <strong class="title"><span>Popup title</span></strong>
// </div>
// <div class="popup content">
// <p>Popup content</p>
// </div>
// <div class="popup footer">
// <div class="actions toolbar">
// <div class="primary">
// <button type="submit" class="action submit"><span>Primary Action</span></button>
// </div>
// <div class="secondary">
// <button type="button" class="action close" data-dismiss="popup"><span>Close</span></button>
// </div>
// </div>
// </div>
// </div>
// ```
.window.popup.popup-example {
.lib-popup();
}
.window.popup.popup-example-1 {
.lib-popup();
}
.window.overlay {
.lib-window-overlay();
}
// #Popup variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Global variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_popup-width</th>
// <td>@popup__width</td>
// <td class="vars_value">auto</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup width</td>
// </tr>
// <tr>
// <th>@_popup-height</th>
// <td>@popup__height</td>
// <td class="vars_value">auto</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup height</td>
// </tr>
// <tr>
// <th>@_popup-padding</th>
// <td>@popup__padding</td>
// <td class="vars_value">22px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Inner popup padding</td>
// </tr>
// <tr>
// <th>@_popup-background</th>
// <td>@popup__background</td>
// <td class="vars_value">@color-white</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup background</td>
// </tr>
// <tr>
// <th>@_popup-border</th>
// <td>@popup__border</td>
// <td class="vars_value">1px solid #aeaeae</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup border</td>
// </tr>
// <tr>
// <th>@_popup-shadow</th>
// <td>@popup__shadow</td>
// <td class="vars_value">0 3px 3px rgba(0,0,0,.15)</td>
// <td class="vars_value">'' | false | none | value</td>
// <td>Popup shadow</td>
// </tr>
// <tr>
// <th>@_popup-fade</th>
// <td>@popup__fade</td>
// <td class="vars_value">opacity .3s linear</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup overlay opacity</td>
// </tr>
// <tr>
// <th>@_popup-z-index</th>
// <td>@popup__z-index</td>
// <td class="vars_value">1001</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup z-index</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Popup position</th>
// </tr>
// <tr>
// <th>@_popup-position</th>
// <td>@popup__position</td>
// <td class="vars_value">fixed</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup position</td>
// </tr>
// <tr>
// <th>@_popup-position-top</th>
// <td>@popup__position-top</td>
// <td class="vars_value">0</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup top</td>
// </tr>
// <tr>
// <th>@_popup-position-right</th>
// <td>@popup__position-right</td>
// <td class="vars_value">0</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup right</td>
// </tr>
// <tr>
// <th>@_popup-position-bottom</th>
// <td>@popup__position-bottom</td>
// <td class="vars_value">0</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup bottom</td>
// </tr>
// <tr>
// <th>@_popup-position-left</th>
// <td>@popup__position-left</td>
// <td class="vars_value">0</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup left</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Popup margin</th>
// </tr>
//
// <tr>
// <th>@_popup-margin-top</th>
// <td>@popup__margin-top</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup top margin</td>
// </tr>
// <tr>
// <th>@_popup-margin-right</th>
// <td>@popup__margin-right</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup right margin</td>
// </tr>
// <tr>
// <th>@_popup-margin-bottom</th>
// <td>@popup__margin-bottom</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup bottom margin</td>
// </tr>
// <tr>
// <th>@_popup-margin-left</th>
// <td>@popup__margin-left</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup left margin</td>
// </tr>
// <tr>
// <th>@_popup-content-height</th>
// <td>@popup-content__height</td>
// <td class="vars_value">auto</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup content height</td>
// </tr>
// <tr>
// <th>@_popup-header-margin</th>
// <td>@popup-header__margin</td>
// <td class="vars_value">0 0 25px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup header margin</td>
// </tr>
// <tr>
// <th>@_popup-content-margin</th>
// <td>@popup-content__margin</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup content margin</td>
// </tr>
// <tr>
// <th>@_popup-footer-margin</th>
// <td>@popup-footer__margin</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup footer margin</td>
// </tr>
// <tr>
// <th>@_popup-title-headings</th>
// <td>@popup-title-headings</td>
// <td class="vars_value">true</td>
// <td class="vars_value">true | false</td>
// <td>Popup title has the same style as one of page headings</td>
// </tr>
// <tr>
// <th>@_popup-title-headings-level</th>
// <td>@popup-title-headings__level</td>
// <td class="vars_value">h3</td>
// <td class="vars_value">h1 | h2 | h3 | h4 | h5 | h6</td>
// <td>What heading style is applied to the popup title</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Popup close button</th>
// </tr>
// <tr>
// <th>@_popup-button-close-icon</th>
// <td>@popup-button-close__icon</td>
// <td class="vars_value">true</td>
// <td class="vars_value">true | false</td>
// <td>Popup close button has an icon</td>
// </tr>
// <tr>
// <th>@_popup-button-close-reset</th>
// <td>@popup-button-close__reset</td>
// <td class="vars_value">true</td>
// <td class="vars_value">true | false</td>
// <td>Reset popup close button default styles</td>
// </tr>
// <tr>
// <th>@_popup-button-close-position</th>
// <td>@popup-button-close__position</td>
// <td class="vars_value">absolute</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup button close position</td>
// </tr>
// <tr>
// <th>@_popup-button-close-position-top</th>
// <td>@popup-button-close__position-top</td>
// <td class="vars_value">10px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup button close top position</td>
// </tr>
// <tr>
// <th>@_popup-button-close-position-right</th>
// <td>@popup-button-close__position-right</td>
// <td class="vars_value">10px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup button close right position</td>
// </tr>
// <tr>
// <th>@_popup-button-close-position-bottom</th>
// <td>@popup-button-close__position-bottom</td>
// <td class="vars_value">''</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup button close bottom position</td>
// </tr>
// <tr>
// <th>@_popup-button-close-position-left</th>
// <td>@popup-button-close__position-left</td>
// <td class="vars_value">''</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup button close left position</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Popup icons parameters</th>
// </tr>
// <tr>
// <th>@_popup-icon-font-content</th>
// <td>@popup-icon-font__content</td>
// <td class="vars_value">@icon-remove</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup icon code</td>
// </tr>
// <tr>
// <th>@_popup-icon-font</th>
// <td>@popup-icon-font</td>
// <td class="vars_value">@button-icon__font</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup icon font</td>
// </tr>
// <tr>
// <th>@_popup-icon-font-size</th>
// <td>@popup-icon-font__size</td>
// <td class="vars_value">@button-icon__font-size</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup icon font size</td>
// </tr>
// <tr>
// <th>@_popup-icon-font-line-height</th>
// <td>@popup-icon-font__line-height</td>
// <td class="vars_value">@button-icon__line-height</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup icon line height</td>
// </tr>
// <tr>
// <th>@_popup-icon-font-color</th>
// <td>@popup-icon-font__color</td>
// <td class="vars_value">@button-icon__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup icon color</td>
// </tr>
// <tr>
// <th>@_popup-icon-font-color-hover</th>
// <td>@popup-icon-font__color-hover</td>
// <td class="vars_value">@button-icon__hover__font-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Hovered popup icon color</td>
// </tr>
// <tr>
// <th>@_popup-icon-font-color-active</th>
// <td>@popup-icon-font__color-active</td>
// <td class="vars_value">@popup-icon-font__color-active</td>
// <td class="vars_value">'' | false | value</td>
// <td>Active popup icon color</td>
// </tr>
// <tr>
// <th>@_popup-icon-font-margin</th>
// <td>@popup-icon-font__margin</td>
// <td class="vars_value">@button-icon__margin</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup icon margin</td>
// </tr>
// <tr>
// <th>@_popup-icon-font-vertical-align</th>
// <td>@popup-icon-font__vertical-align</td>
// <td class="vars_value">@button-icon__vertical-align</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup icon vertical align</td>
// </tr>
// <tr>
// <th>@_popup-icon-font-position</th>
// <td>@popup-icon-font__position</td>
// <td class="vars_value">@button-icon__position</td>
// <td class="vars_value">'' | false | value</td>
// <td>Popup icon position</td>
// </tr>
// <tr>
// <th>@_popup-icon-font-text-hide</th>
// <td>@popup-icon-font__text-hide</td>
// <td class="vars_value">true</td>
// <td class="vars_value">true | false</td>
// <td>Popup icon hide text</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Actions toolbar parameters</th>
// </tr>
// <tr>
// <th>@_popup-actions-toolbar</th>
// <td>@popup-actions-toolbar</td>
// <td class="vars_value">false</td>
// <td class="vars_value">true | false</td>
// <td>Actions toolbar is displayed</td>
// </tr>
// <tr>
// <th>@_popup-actions-toolbar-actions-position</th>
// <td>@popup-actions-toolbar-actions__position</td>
// <td class="vars_value">@actions-toolbar-actions__position</td>
// <td class="vars_value">justify | left | right | center</td>
// <td>Actions toolbar position</td>
// </tr>
// <tr>
// <th>@_popup-actions-toolbar-actions-reverse</th>
// <td>@popup-actions-toolbar-actions__reverse</td>
// <td class="vars_value">@actions-toolbar-actions__reverse</td>
// <td class="vars_value">true | false</td>
// <td>Actions toolbar reverse</td>
// </tr>
// <tr>
// <th>@_popup-actions-toolbar-margin</th>
// <td>@popup-actions-toolbar__margin</td>
// <td class="vars_value">@actions-toolbar__margin</td>
// <td class="vars_value">'' | false | value</td>
// <td>Actions toolbar margin</td>
// </tr>
// <tr>
// <th>@_popup-actions-toolbar-padding</th>
// <td>@popup-actions-toolbar__padding</td>
// <td class="vars_value">@actions-toolbar__padding</td>
// <td class="vars_value">'' | false | value</td>
// <td>Actions toolbar padding</td>
// </tr>
// <tr>
// <th>@_popup-actions-toolbar-actions-margin</th>
// <td>@popup-actions-toolbar-actions__margin</td>
// <td class="vars_value">@actions-toolbar-actions__margin</td>
// <td class="vars_value">'' | false | value</td>
// <td>Actions toolbar actions margin</td>
// </tr>
// <tr>
// <th>@_popup-actions-toolbar-primary-actions-margin</th>
// <td>@popup-actions-toolbar-actions-primary__margin</td>
// <td class="vars_value">@actions-toolbar-actions-primary__margin</td>
// <td class="vars_value">'' | false | value</td>
// <td>Actions toolbar primary actions margin</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_popup-actions-toolbar-secondary-actions-margin</th>
// <td>@popup-actions-toolbar-actions-secondary__margin</td>
// <td class="vars_value"nowrap="nowrap">@actions-toolbar-actions-secondary__margin</td>
// <td class="vars_value">'' | false | value</td>
// <td>Actions toolbar secondary actions margin</td>
// </tr>
// <tr>
// <th>@_popup-actions-toolbar-actions-links-margin-top</th>
// <td>@popup-actions-toolbar-actions-links__margin-top</td>
// <td class="vars_value">@actions-toolbar-actions-links__margin-top</td>
// <td class="vars_value">'' | false | value</td>
// <td>Actions toolbar links top margin</td>
// </tr>
// <tr>
// <th>@_popup-actions-toolbar-primary-actions-links-margin-top</th>
// <td>@popup-actions-toolbar-actions-links-primary__margin-top</td>
// <td class="vars_value">@actions-toolbar-actions-links-primary__margin-top</td>
// <td class="vars_value">'' | false | value</td>
// <td>Actions toolbar primary actions links top margin</td>
// </tr>
// <tr>
// <th>@_popup-actions-toolbar-secondary-links-margin-top</th>
// <td>@popup-actions-toolbar-actions-links-secondary__margin-top</td>
// <td class="vars_value">@actions-toolbar-actions-links-secondary__margin-top</td>
// <td class="vars_value">'' | false | value</td>
// <td>Actions toolbar secondary links top margin</td>
// </tr>
// </table>
// </pre>
//
// # Window overlay mixin variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Global variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_overlay-background</th>
// <td>@overlay__background</td>
// <td class="vars_value">#000</td>
// <td class="vars_value">'' | false | value</td>
// <td>Overlay background color</td>
// </tr>
// <tr>
// <th>@_overlay-opacity</th>
// <td>@overlay__opacity</td>
// <td class="vars_value">.5</td>
// <td class="vars_value">'' | false | value</td>
// <td>Overlay opacity</td>
// </tr>
// <tr>
// <th>@_overlay-opacity-old</th>
// <td>@overlay__opacity-old</td>
// <td class="vars_value">50</td>
// <td class="vars_value">'' | false | value</td>
// <td>Overlay opacity for old browsers</td>
// </tr>
// <tr>
// <th>@_overlay-fade</th>
// <td>@overlay__fade</td>
// <td class="vars_value">opacity .15s linear</td>
// <td class="vars_value">'' | false | value</td>
// <td>Overlay fade</td>
// </tr>
// <tr>
// <th>@_overlay-z-index</th>
// <td>@overlay__z-index</td>
// <td class="vars_value">1000</td>
// <td class="vars_value">'' | value</td>
// <td>Overlay z-index</td>
// </tr>
// </table>
// </pre>
//
// # Fixed height popup
//
// To get a fixed height popup set the desired value for <code>@_popup-height</code> variable:
// ``` html
// <button type="button" class="action toggle" data-toggle="popup" data-backdrop="true" data-target="#window-popup" aria-expanded="false" aria-controls="window-popup"><span>Show popup</span></button>
// <div class="window popup popup-example-2" id="window-popup" tabindex="-1" role="dialog" aria-labelledby="popup-title" aria-describedby="popup-content" aria-hidden="true">
// <div class="popup actions">
// <div class="secondary">
// <button type="button" class="action close" data-dismiss="popup"><span>Close</span></button>
// </div>
// </div>
// <div class="popup header">
// <strong class="title" id="popup-title"><span>Popup title</span></strong>
// </div>
// <div class="popup content" id="popup-content">
// <p>Popup content Popup contentPopup content Popup contentPopup content Popup contentPopup contentPopup content Popup contentPopup content Popup contentPopup content Popup contentPopup contentPopup content Popup contentPopup content Popup contentPopup content Popup contentPopup content Popup contentPopup content Popup contentPopup content Popup contentPopup content Popup contentPopup content Popup contentPopup content Popup contentPopup content Popup contentPopup content Popup contentPopup content Popup content</p>
// </div>
// <div class="popup footer"></div>
// </div>
// ```
.window.popup.popup-example-2 {
.lib-popup(
@_popup-height: 200px
);
}
// # Fixed content height popup
// To get a fixed height popup content set the desired value for <code>@_popup-content-height</code> variable:
//
// ``` html
// <button type="button" class="action toggle" data-toggle="popup" data-backdrop="true" data-target="#window-popup" aria-expanded="false" aria-controls="window-popup"><span>Show popup</span></button>
// <div class="window popup popup-example-3" id="window-popup" tabindex="-1" role="dialog" aria-labelledby="popup-title" aria-describedby="popup-content" aria-hidden="true">
// <div class="popup actions">
// <div class="secondary">
// <button type="button" class="action close" data-dismiss="popup"><span>Close</span></button>
// </div>
// </div>
// <div class="popup header">
// <strong class="title" id="popup-title"><span>Popup title</span></strong>
// </div>
// <div class="popup content" id="popup-content">
// <p>Popup content Popup contentPopupPopup content Popup contentPopupPopup content Popup contentPopupPopup content Popup contentPopupPopup content Popup contentPopup Popup content Popup contentPopup Popup content Popup contentPopup Popup content Popup contentPopup Popup content Popup contentPopup content Popup contentPopup content Popup contentPopup content Popup contentPopup content Popup contentPopup content Popup contentPopup content Popup contentPopup content Popup contentPopup content Popup contentPopup content Popup contentPopup content Popup contentPopup content Popup content</p>
// </div>
// <div class="popup footer"></div>
// </div>
// ```
.window.popup.popup-example-3 {
.lib-popup(
@_popup-content-height: 200px
);
}
// # Margins for header, content and footer block in popup
//
// To set margins to header, content and footer block in popup, use variables:
// ```css
// @_popup-header-margin: value,
// @_popup-content-margin: value,
// @_popup-footer-margin: value
// ```
// ``` html
// <button type="button" class="action toggle" data-toggle="popup" data-backdrop="true" data-target="#window-popup" aria-expanded="false" aria-controls="window-popup"><span>Show popup</span></button>
// <div class="window popup popup-example-4" id="window-popup" tabindex="-1" role="dialog" aria-labelledby="popup-title" aria-describedby="popup-content" aria-hidden="true">
// <div class="popup actions">
// <div class="secondary">
// <button type="button" class="action close" data-dismiss="popup"><span>Close</span></button>
// </div>
// </div>
// <div class="popup header">
// <strong class="title" id="popup-title"><span>Popup title</span></strong>
// </div>
// <div class="popup content" id="popup-content">
// <p>Popup content</p>
// </div>
// <div class="popup footer">
// <div class="actions toolbar">
// <div class="primary">
// <button type="submit" class="action submit"><span>Primary Action</span></button>
// </div>
// <div class="secondary">
// <button type="button" class="action close" data-dismiss="popup"><span>Close</span></button>
// </div>
// </div>
// </div>
// </div>
// ```
.window.popup.popup-example-4 {
.lib-popup(
@_popup-header-margin: 0 0 25px,
@_popup-content-margin: 0 0 20px,
@_popup-footer-margin: 0 20px
);
}
// # Popup titles styled as theme headings
//
// To enable inheritance of the page heading style for popup title set:
// ```css
// @_popup-title-headings: true
// ```
// To set the page heading to inherit use:
// ```css
// @_popup-title-headings-level: h3 // h1, h2, h3, h4, h5, h6
// ```
// ``` html
// <button type="button" class="action toggle" data-toggle="popup" data-backdrop="true" data-target="#window-popup" aria-expanded="false" aria-controls="window-popup"><span>Show popup</span></button>
// <div class="window popup popup-example-5" id="window-popup" tabindex="-1" role="dialog" aria-labelledby="popup-title" aria-describedby="popup-content" aria-hidden="true">
// <div class="popup actions">
// <div class="secondary">
// <button type="button" class="action close" data-dismiss="popup"><span>Close</span></button>
// </div>
// </div>
// <div class="popup header">
// <strong class="title" id="popup-title"><span>Popup title</span></strong>
// </div>
// <div class="popup content" id="popup-content">
// <p>Popup content</p>
// </div>
// <div class="popup footer">
// <div class="actions toolbar">
// <div class="primary">
// <button type="submit" class="action submit"><span>Primary Action</span></button>
// </div>
// <div class="secondary">
// <button type="button" class="action close" data-dismiss="popup"><span>Close</span></button>
// </div>
// </div>
// </div>
// </div>
// ```
.window.popup.popup-example-5 {
.lib-popup(
@_popup-title-headings: true,
@_popup-title-headings-level: h1
);
}
// # Popup action toolbar
//
// The <code>.lib-popup()</code> mixin uses the same variables as <code>.actions-toolbar()</code>, but with <code>'@_popup-'</code> prefix added.
//
// To use variables from the <code>.actions-toolbar()</code> mixin set:
// ```css
// @_popup-actions-toolbar: true // false
// ```
// More information about parameters you will find at **Actions-toolbar** page.
// ``` html
// <button type="button" class="action toggle" data-toggle="popup" data-backdrop="true" data-target="#window-popup" aria-expanded="false" aria-controls="window-popup"><span>Show popup</span></button>
// <div class="window popup popup-example-6" id="window-popup" tabindex="-1" role="dialog" aria-labelledby="popup-title" aria-describedby="popup-content" aria-hidden="true">
// <div class="popup actions">
// <div class="secondary">
// <button type="button" class="action close" data-dismiss="popup"><span>Close</span></button>
// </div>
// </div>
// <div class="popup header">
// <strong class="title" id="popup-title"><span>Popup title</span></strong>
// </div>
// <div class="popup content" id="popup-content">
// <p>Popup content</p>
// </div>
// <div class="popup footer">
// <div class="actions toolbar">
// <div class="primary">
// <button type="submit" class="action submit"><span>Primary Action</span></button>
// </div>
// <div class="secondary">
// <button type="button" class="action close" data-dismiss="popup"><span>Close</span></button>
// </div>
// </div>
// </div>
// </div>
// ```
.window.popup.popup-example-6 {
.lib-popup(
@_popup-actions-toolbar: true,
@_popup-actions-toolbar-actions-position: left,
@_popup-actions-toolbar-actions-reverse: true
);
}
// # Popup Close button without an icon
// You can set the popup close button to inherit theme's default button styles without an icon.
// ```css
// @_popup-button-close-icon: false,
// @_popup-button-close-reset: false
// ```
// ``` html
// <button type="button" class="action toggle" data-toggle="popup" data-backdrop="true" data-target="#window-popup" aria-expanded="false" aria-controls="window-popup"><span>Show popup</span></button>
// <div class="window popup popup-example-7" id="window-popup" tabindex="-1" role="dialog" aria-labelledby="popup-title" aria-describedby="popup-content" aria-hidden="true">
// <div class="popup actions">
// <div class="secondary">
// <button type="button" class="action close" data-dismiss="popup"><span>Close</span></button>
// </div>
// </div>
// <div class="popup header">
// <strong class="title" id="popup-title"><span>Popup title</span></strong>
// </div>
// <div class="popup content" id="popup-content">
// <p>Popup content</p>
// </div>
// <div class="popup footer">
// <div class="actions toolbar">
// <div class="primary">
// <button type="submit" class="action submit"><span>Primary Action</span></button>
// </div>
// <div class="secondary">
// <button type="button" class="action close" data-dismiss="popup"><span>Close</span></button>
// </div>
// </div>
// </div>
// </div>
// ```
.window.popup.popup-example-7 {
.lib-popup(
@_popup-button-close-icon: false,
@_popup-button-close-reset: false
);
}
// # Modify the icon of popup Close button
//
// The <code>.lib-popup()</code> mixin uses all the same variables as <code>.icon-font()</code> mixin with <code>'@_popup-'</code> prefix added. More information about <code>.lib-icon-font()</code> parameters you can find at **Icons** page
//
// ``` html
// <button type="button" class="action toggle" data-toggle="popup" data-backdrop="true" data-target="#window-popup" aria-expanded="false" aria-controls="window-popup"><span>Show popup</span></button>
// <div class="window popup popup-example-8" id="window-popup" tabindex="-1" role="dialog" aria-labelledby="popup-title" aria-describedby="popup-content" aria-hidden="true">
// <div class="popup actions">
// <div class="secondary">
// <button type="button" class="action close" data-dismiss="popup"><span>Close</span></button>
// </div>
// </div>
// <div class="popup header">
// <strong class="title" id="popup-title"><span>Popup title</span></strong>
// </div>
// <div class="popup content" id="popup-content">
// <p>Popup content</p>
// </div>
// <div class="popup footer">
// <div class="actions toolbar">
// <div class="primary">
// <button type="submit" class="action submit"><span>Primary Action</span></button>
// </div>
// <div class="secondary">
// <button type="button" class="action close" data-dismiss="popup"><span>Close</span></button>
// </div>
// </div>
// </div>
// </div>
// ```
.window.popup.popup-example-8 {
.lib-popup(
@_popup-icon-font-content: @icon-arrow-up,
@_popup-icon-font-color: #f00,
@_popup-icon-font-color-hover: #090,
@_popup-icon-font-color-active: #00f,
@_popup-icon-font-size: 30px,
@_popup-icon-font-vertical-align: middle,
@_popup-icon-font-text-hide: false
);
}
// # Modify overlay styles
//
// To modify overlay styles use the <code>.lib-window-overlay()</code> mixin
//
// ``` html
// <button type="button" class="action toggle" data-toggle="popup" data-backdrop="true" data-target="#window-popup" aria-expanded="false" aria-controls="window-popup"><span>Show popup</span></button>
// <div class="window popup popup-example-9" id="window-popup" tabindex="-1" role="dialog" aria-labelledby="popup-title" aria-describedby="popup-content" aria-hidden="true">
// <div class="popup actions">
// <div class="secondary">
// <button type="button" class="action close" data-dismiss="popup"><span>Close</span></button>
// </div>
// </div>
// <div class="popup header">
// <strong class="title" id="popup-title"><span>Popup title</span></strong>
// </div>
// <div class="popup content" id="popup-content">
// <p>Popup content</p>
// </div>
// <div class="popup footer">
// <div class="actions toolbar">
// <div class="primary">
// <button type="submit" class="action submit"><span>Primary Action</span></button>
// </div>
// <div class="secondary">
// <button type="button" class="action close" data-dismiss="popup"><span>Close</span></button>
// </div>
// </div>
// </div>
// </div>
// <div class="window overlay example-overlay-1 active"></div>
// ```
.window.popup.popup-example-9 {
.lib-popup();
}
.window.overlay.example-overlay-1.active {
.lib-window-overlay(
@_overlay-background: #0f5293,
@_overlay-opacity: .8,
@_overlay-opacity-old: 80
);
}
+437
View File
@@ -0,0 +1,437 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
// # Ratings
//
// Ratings styling mixins are based on using font icons as rate symbols. There are two types of ratings: rating which allows user to vote and rating which displays voting results summary. Depending on the rating type mixin <code>.lib-rating-vote()</code> or <code>.lib-rating-summary()</code> is used.
//
// # Global rating variables
//
// Global styles for both types of ratings can be modified by changing global variables. To set different styles to types of ratings these variables should be used directly in the mixin call.
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Global variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_icon-content</th>
// <td>@rating-icon__content</td>
// <td class="vars_value">@icon-star</td>
// <td class="vars_value">'' | false | icon code</td>
// <td>Rating icon symbol code</td>
// </tr>
// <tr>
// <th>@_icon-count</th>
// <td>@rating-icon__count</td>
// <td class="vars_value">5</td>
// <td class="vars_value">'' | value</td>
// <td>Number of rating icon symbols</td>
// </tr>
// <tr>
// <th>@_icon-font</th>
// <td>@rating-icon__font</td>
// <td class="vars_value">@icon-font</td>
// <td class="vars_value">'' | false | value</td>
// <td>Icon font</td>
// </tr>
// <tr>
// <th>@_icon-font-size</th>
// <td>@rating-icon__font-size</td>
// <td class="vars_value">28px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Icon font size</td>
// </tr>
// <tr>
// <th>@_icon-letter-spacing</th>
// <td>@rating-icon__letter-spacing</td>
// <td class="vars_value">-10px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Icon letter spacing</td>
// </tr>
// <tr>
// <th>@_icon-color</th>
// <td>@rating-icon__color</td>
// <td class="vars_value">#c7c7c7</td>
// <td class="vars_value">'' | false | value</td>
// <td>Unselected icons color</td>
// </tr>
// <tr>
// <th>@_icon-color-active</th>
// <td>@rating-icon__active__color</td>
// <td class="vars_value">#ff5601</td>
// <td class="vars_value">'' | false | value</td>
// <td>Selected and hovered icons color</td>
// </tr>
// <tr>
// <th>@_label-hide</th>
// <td>@rating-label__hide</td>
// <td class="vars_value">false</td>
// <td class="vars_value">true | false</td>
// <td>Rating label is displayed</td>
// </tr>
// </table>
// </pre>
//
// # Rating with vote
//
// To implement rating with vote, use the <code>.lib-rating-vote()</code> mixin.
// ``` html
// <div class="rating vote example-ratings-1">
// <input type="radio" name="rating-price" id="rating-price-1" value="1" />
// <label class="rating-1" for="rating-price-1" title="1 star">
// <span>1 star</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-2" value="2" />
// <label class="rating-2" for="rating-price-2" title="2 stars">
// <span>2 stars</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-3" value="3" />
// <label class="rating-3" for="rating-price-3" title="3 stars">
// <span>3 stars</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-4" value="4" />
// <label class="rating-4" for="rating-price-4" title="4 stars">
// <span>4 stars</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-5" value="5" />
// <label class="rating-5" for="rating-price-5" title="5 stars">
// <span>5 stars</span>
// </label>
// </div>
// ```
.example-ratings-1 {
.lib-rating-vote();
}
// # Rating with vote icons number customization
//
// To change number of icons, add desired number of rating icons (input + label) to the markup. Then set this number to the <code>@_icon-count</code> mixin variable.
//
// ``` html
// <div class="rating vote example-ratings-2">
// <input type="radio" name="rating-price" id="rating-price-1" value="1" />
// <label class="rating-1" for="rating-price-1" title="1 star">
// <span>1 star</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-2" value="2" />
// <label class="rating-2" for="rating-price-2" title="2 stars">
// <span>2 stars</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-3" value="3" />
// <label class="rating-3" for="rating-price-3" title="3 stars">
// <span>3 stars</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-4" value="4" />
// <label class="rating-4" for="rating-price-4" title="4 stars">
// <span>4 stars</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-5" value="5" />
// <label class="rating-5" for="rating-price-5" title="5 stars">
// <span>5 stars</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-6" value="6" />
// <label class="rating-6" for="rating-price-6" title="6 stars">
// <span>6 stars</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-7" value="7" />
// <label class="rating-7" for="rating-price-7" title="7 stars">
// <span>7 stars</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-8" value="8" />
// <label class="rating-8" for="rating-price-8" title="8 stars">
// <span>8 stars</span>
// </label>
// </div>
// ```
.example-ratings-2 {
.lib-rating-vote(
@_icon-count: 8
);
}
// # Rating with vote icons colors customization
//
// These variables control default and active icon colors:
// ```css
// @_icon-color: value,
// @_icon-color-active: value
// ```
//
// ``` html
// <div class="rating vote example-ratings-3">
// <input type="radio" name="rating-price" id="rating-price-1" value="1" />
// <label class="rating-1" for="rating-price-1" title="1 star">
// <span>1 star</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-2" value="2" />
// <label class="rating-2" for="rating-price-2" title="2 stars">
// <span>2 stars</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-3" value="3" />
// <label class="rating-3" for="rating-price-3" title="3 stars">
// <span>3 stars</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-4" value="4" />
// <label class="rating-4" for="rating-price-4" title="4 stars">
// <span>4 stars</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-5" value="5" />
// <label class="rating-5" for="rating-price-5" title="5 stars">
// <span>5 stars</span>
// </label>
// </div>
// ```
.example-ratings-3 {
.lib-rating-vote(
@_icon-color: #aff5e3,
@_icon-color-active: #0a6767
);
}
// # Rating with vote icons symbol customization
//
// To set custom icon symbol, use the <code>@_icon-content</code> variable
//
// ``` html
// <div class="rating vote example-ratings-4">
// <input type="radio" name="rating-price" id="rating-price-1" value="1" />
// <label class="rating-1" for="rating-price-1" title="1 star">
// <span>1 star</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-2" value="2" />
// <label class="rating-2" for="rating-price-2" title="2 stars">
// <span>2 stars</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-3" value="3" />
// <label class="rating-3" for="rating-price-3" title="3 stars">
// <span>3 stars</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-4" value="4" />
// <label class="rating-4" for="rating-price-4" title="4 stars">
// <span>4 stars</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-5" value="5" />
// <label class="rating-5" for="rating-price-5" title="5 stars">
// <span>5 stars</span>
// </label>
// </div>
// ```
.example-ratings-4 {
.lib-rating-vote(
@_icon-content: @icon-wishlist-full
);
}
// # Accessible rating with vote
//
// The following markup corresponds to **accessibility** demands
// ``` html
// <fieldset class="exapmle-ratings-5 fieldset ratings vote">
// <legend>How do you rate this product?</legend>
// <div class="field price">
// <label class="label" for="rating-1" id="price-rating-label"><span>Price</span></label>
// <div class="control rating vote">
// <input type="radio" name="rating-price" id="rating-price-1" value="1" aria-labelledby="price-rating-label rating-price-label-1" />
// <label class="rating-1" for="rating-price-1" title="1 star" id="rating-price-label-1">
// <span>1 star</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-2" value="2" aria-labelledby="price-rating-label rating-price-label-2" />
// <label class="rating-2" for="rating-price-2" title="2 stars" id="rating-price-label-2">
// <span>2 stars</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-3" value="3" aria-labelledby="price-rating-label rating-price-label-3" />
// <label class="rating-3" for="rating-price-3" title="3 stars" id="rating-price-label-3">
// <span>3 stars</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-4" value="4" aria-labelledby="price-rating-label rating-price-label-4" />
// <label class="rating-4" for="rating-price-4" title="4 stars" id="rating-price-label-4">
// <span>4 stars</span>
// </label>
// <input type="radio" name="rating-price" id="rating-price-5" value="5" aria-labelledby="price-rating-label rating-price-label-5" />
// <label class="rating-5" for="rating-price-5" title="5 stars" id="rating-price-label-5">
// <span>5 stars</span>
// </label>
// </div>
// </div>
// </fieldset>
// ```
.exapmle-ratings-5 {
.control.rating.vote {
.lib-rating-vote();
}
}
// # Rating summary
//
// To implement rating summary, use the following markup
// ``` html
// <div class="example-rating-summary-1">
// <span class="label"><span>Rating</span></span>
// <div class="rating-result" title="60%">
// <span style="width:60%"><span>60</span></span>
// </div>
// </div>
// ```
.example-rating-summary-1 {
.lib-rating-summary();
}
// # Rating summary icons number customization
//
// To set up number of icons, use the variable:
// ```css
// @_icon-count: number
// ```
//
// ``` html
// <div class="example-rating-summary-2">
// <span class="label"><span>Rating</span></span>
// <div class="rating-result" title="40%">
// <span style="width:40%"><span>40</span></span>
// </div>
// </div>
// ```
.example-rating-summary-2 {
.lib-rating-summary(
@_icon-count: 8
);
}
// # Rating summary icons color customization
//
// To set up the icons default and selected color, use variables:
// ```css
// @_icon-color: value
// @_icon-color-active: value
// ```
//
// ``` html
// <div class="example-rating-summary-3">
// <span class="label"><span>Rating</span></span>
// <div class="rating-result" title="40%">
// <span style="width:40%"><span>40</span></span>
// </div>
// </div>
// ```
.example-rating-summary-3 {
.lib-rating-summary(
@_icon-color: #aff5e3,
@_icon-color-active: #0a6767
);
}
// # Rating summary icons symbol customization
//
// To set up the icons symbol use variable:
// ```css
// @_icon-content: icon_code
// ```
//
// ``` html
// <div class="example-rating-summary-4">
// <span class="label"><span>Rating</span></span>
// <div class="rating-result" title="40%">
// <span style="width:40%"><span>40</span></span>
// </div>
// </div>
// ```
.example-rating-summary-4 {
.lib-rating-summary(
@_icon-content: @icon-wishlist-full
);
}
// # Rating summary hide label
//
// To hide the rating summary label set:
// ```css
// @_label-hide: true
// ```
//
// ``` html
// <div class="example-rating-summary-5">
// <span class="label"><span>Rating</span></span>
// <div class="rating-result" title="40%">
// <span style="width:40%"><span>40</span></span>
// </div>
// </div>
// ```
.example-rating-summary-5 {
.lib-rating-summary(
@_label-hide: true
);
}
// # Rating summary multiple ratings
//
// ``` html
// <div class="example-rating-summary-6" tabindex="1">
// <strong>Your Rating:</strong>
// <div class="rating-summary item">
// <span class="label"><span>Value</span></span>
// <div class="rating-result" title="100%" >
// <span style="width:100%"><span>100%</span></span>
// </div>
// </div>
// <div class="rating-summary item">
// <span class="label"><span>Quality</span></span>
// <div class="rating-result" title="100%">
// <span style="width:100%"><span>100%</span></span>
// </div>
// </div>
// <div class="rating-summary item">
// <span class="label"><span>rating +</span></span>
// <div class="rating-result" title="20%">
// <span style="width:20%"><span>20%</span></span>
// </div>
// </div>
// <div class="rating-summary item">
// <span class="label"><span>Price</span></span>
// <div class="rating-result" title="40%">
// <span style="width:40%"><span>40%</span></span>
// </div>
// </div>
// </div>
// ```
.example-rating-summary-6 {
.rating-summary {
.lib-rating-summary();
}
}
// # Rating hide label mixin
//
// The <code>.lib-rating-summary-label-hide()</code> mixin is used to hide rating label in summary rating.
//
// ``` html
// <div class="example-rating-summary-7">
// <span class="label"><span>Rating</span></span>
// <div class="rating-result" title="40%">
// <span style="width:40%"><span>40</span></span>
// </div>
// </div>
// ```
.example-rating-summary-7 {
.lib-rating-summary();
.lib-rating-summary-label-hide();
}
+64
View File
@@ -0,0 +1,64 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
// # Resets
// CSS reset is a technique that makes selected elements display in the same way in different browsers by default.
//
// In Magento UI library there are 5 pre-defined resets that can be called by appropriate mixin..
//
// ## Magento reset
// Magento UI library has a set of variables that configure UI elements. Magento reset uses this list to define the default state of html elements. It sets up the basic typography, forms style, buttons style, tables style using variables which are specified in your theme. Magento reset is made to avoid re-defining same elements by using some reset techniques and then set up different styles to these elements.
//
// To get Magento UI library reset in your theme, use mixin:
//
// ```CSS
// .lib-magento-reset();
// ```
//
// ## Normalize.css v3
// Normalize.css is a known CSS reset that makes browsers render all elements more consistently with current modern standards requirements.
//
// To get normalize reset in your theme, use mixin:
//
// ```CSS
// .lib-normalize();
// ```
//
// ## Reset CSS v2.0
// The goal of a reset stylesheet is to reduce browser inconsistency in basic elements: default line heights, margins and font sizes of headings, and so on.
//
// To get reset CSS in your theme, use mixin:
//
// ```CSS
// .lib-reset();
// ```
//
// ## Universal Selector ‘*’ Reset
// This reset defines all elements' margin and padding to 0.
//
// To get universal selector ‘*’ reset in your theme, use mixin:
//
// ```CSS
// .lib-universal();
// ```
//
// ## Html5doctor Reset Stylesheet v1.6.1
// Html5doctor reset is a reset mixin that includes all html5 elements. Deprecated elements (like <code>&lt;acronym&gt;</code>, <code>&lt;center&gt;</code> and <code>&lt;big&gt;</code>) are removed.
//
// To get html5doctor reset in your theme, use mixin:
//
// ```CSS
// .lib-html5doctor-reset();
// ```
//
// ## Global border-box
// This mixin defines all elements' <code>box-sizing</code> to <code>border-box</code>.
//
// To set <code>box-sizing: border-box</code> globally, use mixin:
//
// ```CSS
// .lib-set-default-border-box();
// ```
// &nbsp;
+108
View File
@@ -0,0 +1,108 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
// # Responsive
// Magento UI library provides a strong approach for working with media queries. It`s based on recursive call of <span style="white-space: nowrap"><code>.media-width()</code></span> mixin defined anywhere in project but invoked in one place in <span style="white-space: nowrap"><code>lib/web/css/source/lib/_responsive.less</code></span>. That's why in the resulting <code>styles.css</code> we have every media query only once with all the rules there, not a multiple calls for the same query.
//
// To see the media queries work resize window to understand which breakpoint is applied.
// ```
// <div class="example-responsive-block">
// are applied.
// </div>
// ```
.example-responsive-block {
padding: 10px;
}
.media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__m) {
.example-responsive-block {
background: #ffc;
}
.example-responsive-block:before {
content: 'Mobile styles ';
font-weight: bold;
}
}
.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @screen__m) {
.example-responsive-block {
background: #ccf;
}
.example-responsive-block:before {
content: 'Desktop styles ';
font-weight: bold;
}
}
// # Responsive mixins usage
//
// For grouping style rules in certain media queries .media-width() mixin used.
// ```css
// .media-width(<@extremum>, <@break>);
// ```
// <span style="white-space: nowrap"><code>@extremum: max|min</code></span> - sets whether to use **min-width** or **max-width** in media query condition<br />
// <span style="white-space: nowrap"><code>@break: value</code></span> - sets the value of breakpoint to compare with in media query condition.<br />
// For example
// ```css
// .media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__s) {
// your styles
// }
// ```
// It will be complied to
// ```css
// @media only screen and (max-width: 640px) {
// your styles
// }
// ```
// &nbsp;
//
// # Media query style groups separation variables
//
// <code>@media-common: true|false</code> - sets whether to output common styles.
// For common styles every time you want to add some styles you should use
// ```css
// & when (@media-common = true) {
// your styles
// }
// ```
//
// <code>@media-target: all|desktop|mobile</code> - Sets target device for styles output
// ```css
// & when (@media-target = 'mobile'),
// (@media-target = 'all') {
// @media only screen and (max-width: (@screen__xs - 1)) {
// .media-width('max', @screen__xs);
// }
// }
// ```
//
// ## Gathering
//
// Everything that you include in collector mixins above will go in place where they declared.
// As example all
// ```css
// .media-width(@extremum, @break) {
// your code
// }
// ```
// Will go to
// ```css
// .media-width(@extremum, @break));
// ```
// By default you can find it <code>_responsive.less</code> file in li
// &nbsp;
//
// # Responsive breakpoints
// In Magento UI library there are predefined variables for breakpoints.
// ```css
// @screen__xxs: 320px;
// @screen__xs: 480px;
// @screen__s: 640px;
// @screen__m: 768px;
// @screen__l: 1024px;
// @screen__xl: 1440px;
// ```
// &nbsp;
+691
View File
@@ -0,0 +1,691 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
// # Tabs and accordions
//
// To set up tabs and accordions Magento UI library provides 2 types of mixins: <code>.lib-data-tabs__base()</code> and <code>.lib-data-accordion__base()</code>. These mixins reset markup elements default styles and add minimal required css setup to make these elements work properly.
//
// # Tabs
//
// The <code>.lib-data-tabs()</code> mixin is used to setup tabs parameters.
//
// ```html
// <dl class="example-sections-1" data-sections="tabs">
// <dt class="item title active" data-section="title">
// <a class="switch" data-toggle="switch" href="#product.info.description">Details</a>
// </dt>
// <dd class="item content active" data-section="content">
// <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book.</p>
// </dd>
//
// <dt class="item title" data-section="title">
// <a class="switch" data-toggle="switch" href="#product_tags">Tags</a>
// </dt>
// <dd class="item content" data-section="content">
// <p>It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged.</p>
// </dd>
//
// <dt class="item title" data-section="title">
// <a class="switch" data-toggle="switch" href="#product_reviews">Reviews</a>
// </dt>
// <dd class="item content" data-section="content">
// <p>It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.</p>
// </dd>
// </dl>
// ```
.example-sections-1 {
.lib-data-tabs();
}
// # Tabs mixin variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Global variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_tab-control-font-family</th>
// <td>@tab-control__font-family</td>
// <td class="vars_value">false</td>
// <td class="vars_value" nowrap>'' | false | value</td>
// <td>Tabs font family</td>
// </tr>
// <tr>
// <th>@_tab-control-font-size</th>
// <td>@tab-control__font-size</td>
// <td class="vars_value">@font-size__base</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tabs font size</td>
// </tr>
// <tr>
// <th>@_tab-control-font-weight</th>
// <td>@tab-control__font-weight</td>
// <td class="vars_value">@font-weight__semibold</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tabs font weight</td>
// </tr>
// <tr>
// <th>@_tab-control-font-style</th>
// <td>@tab-control__font-style</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tabs font style</td>
// </tr>
// <tr>
// <th>@_tab-control-line-height</th>
// <td>@tab-control__line-height</td>
// <td class="vars_value">@tab-control__height</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tabs line height</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Tabs controls settings</th>
// </tr>
// <tr>
// <th>@_tab-control-background-color</th>
// <td>@tab-control__background-color</td>
// <td class="vars_value">@panel__background-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Current tab background</td>
// </tr>
// <tr>
// <th>@_tab-control-color</th>
// <td>@tab-control__color</td>
// <td class="vars_value">@link__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Current tab text color</td>
// </tr>
// <tr>
// <th>@_tab-control-text-decoration</th>
// <td>@tab-control__text-decoration</td>
// <td class="vars_value">none</td>
// <td class="vars_value">'' | false | value</td>
// <td>Current tab text-decoration</td>
// </tr>
// <tr>
// <th>@_tab-control-background-color-hover</th>
// <td>@tab-control__hover__background-color</td>
// <td class="vars_value">lighten(@tab-control__background-color, 5%)</td>
// <td class="vars_value">'' | false | value</td>
// <td>Hovered tab background</td>
// </tr>
// <tr>
// <th>@_tab-control-color-visited</th>
// <td>@tab-control__color</td>
// <td class="vars_value">@text__color__muted</td>
// <td class="vars_value">'' | false | value</td>
// <td>Visited tab color</td>
// </tr>
// <tr>
// <th>@_tab-control-text-decoration-visited</th>
// <td>@tab-control__color</td>
// <td class="vars_value"></td>
// <td class="vars_value">'' | false | value</td>
// <td>Visited tab text-decoration</td>
// </tr>
// <tr>
// <th>@_tab-control-color-hover</th>
// <td>@tab-control__hover__color</td>
// <td class="vars_value">@tab-control__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Hovered tab text color</td>
// </tr>
// <tr>
// <th>@_tab-control-text-decoration-hover</th>
// <td>@tab-control__text-decoration</td>
// <td class="vars_value">@tab-control__text-decoration</td>
// <td class="vars_value">'' | false | value</td>
// <td>Hovered tab text-decoration</td>
// </tr>
// <tr>
// <th>@_tab-control-background-color-active</th>
// <td>@tab-control__active__background-color</td>
// <td class="vars_value">lighten(@tab-control__background-color, 15%)</td>
// <td class="vars_value">'' | false | value</td>
// <td>Active tab background</td>
// </tr>
// <tr>
// <th>@_tab-control-color-active</th>
// <td>@tab-control__active__color</td>
// <td class="vars_value">@text__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Active tab text color</td>
// </tr>
// <tr>
// <th>@_tab-control-text-decoration-active</th>
// <td>@tab-control__text-decoration</td>
// <td class="vars_value">@tab-control__text-decoration</td>
// <td class="vars_value">'' | false | value</td>
// <td>Active tab text-decoration</td>
// </tr>
// <tr>
// <th>@_tab-control-height</th>
// <td>@tab-control__height</td>
// <td class="vars_value">@indent__l</td>
// <td class="vars_value">'' | false | value</td>
// <td>Height of tab control</td>
// </tr>
// <tr>
// <th>@_tab-control-margin-right</th>
// <td>@tab-control__margin-right</td>
// <td class="vars_value">@indent__xs</td>
// <td class="vars_value">'' | false | value</td>
// <td>Right margin of tab title block</td>
// </tr>
// <tr>
// <th>@_tab-control-padding-top</th>
// <td>@tab-control__padding-top</td>
// <td class="vars_value">@indent__xs</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tab control padding top</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_tab-control-padding-right</th>
// <td>@tab-control__padding-right</td>
// <td class="vars_value">@indent__base</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tab control padding right</td>
// </tr>
// <tr>
// <th>@_tab-control-padding-bottom</th>
// <td>@tab-control__padding-bottom</td>
// <td class="vars_value">@tab-control__padding-bottom</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tab control padding bottom</td>
// </tr>
// <tr>
// <th>@_tab-control-padding-left</th>
// <td>@tab-control__padding-left</td>
// <td class="vars_value">@tab-control__padding-left</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tab control padding left</td>
// </tr>
// <tr>
// <th>@_tab-control-border-width</th>
// <td>@tab-control__border-width</td>
// <td class="vars_value">@border-width__base</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tab control border width</td>
// </tr>
// <tr>
// <th>@_tab-control-border-color</th>
// <td>@tab-control__border-color</td>
// <td class="vars_value">@border-color__base</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tab control border color</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Tab content settings</th>
// </tr>
// <tr>
// <th>@_tab-content-background-color</th>
// <td>@tab-content__background-color</td>
// <td class="vars_value">@tab-control__active__background-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tab content background</td>
// </tr>
// <tr>
// <th>@_tab-content-border-top-status</th>
// <td>@tab-content__border-top-status</td>
// <td class="vars_value">false</td>
// <td class="vars_value">true | false</td>
// <td>Tab content border top status. When set to 'true' the content has only top border. When set to 'false' the content has all 4 borders</td>
// </tr>
// <tr>
// <th>@_tab-content-border</th>
// <td>@tab-content__border</td>
// <td class="vars_value">@tab-control__border-width solid @tab-control__border-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tab content border</td>
// </tr>
// <tr>
// <th>@_tab-content-margin-top</th>
// <td>@tab-content__margin-top</td>
// <td class="vars_value">@tab-control__height + @tab-control__border-width + @tab-control__padding-top + @tab-control__padding-bottom</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tab content top margin (it is the sum of tabs height and top border width)</td>
// </tr>
// <tr>
// <th>@_tab-content-padding-top</th>
// <td>@tab-content__padding-top</td>
// <td class="vars_value">@indent__base</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tab content padding</td>
// </tr>
// <tr>
// <th>@_tab-content-padding-right</th>
// <td>@tab-content__padding-right</td>
// <td class="vars_value">@indent__base</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tab content padding</td>
// </tr>
// <tr>
// <th>@_tab-content-padding-bottom</th>
// <td>@tab-content__padding-bottom</td>
// <td class="vars_value">@tab-content__padding-top</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tab content padding</td>
// </tr>
// <tr>
// <th>@_tab-content-padding-left</th>
// <td>@tab-content__padding-left</td>
// <td class="vars_value">@tab-content__padding-right</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tab content padding</td>
// </tr>
// </table>
// </pre>
//
// # Tabs with content top border
//
// To set up tabs with only top content border use variable:
// ```css
// @_tab-content-border: true
// ```
//
// ```html
// <dl class="example-sections-2" data-sections="tabs">
// <dt class="item title active" data-section="title">
// <a class="switch" data-toggle="switch" href="#product.info.description">Details</a>
// </dt>
// <dd class="item content active" data-section="content">
// <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book.</p>
// </dd>
//
// <dt class="item title" data-section="title">
// <a class="switch" data-toggle="switch" href="#product_tags">Tags</a>
// </dt>
// <dd class="item content" data-section="content">
// <p>It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged.</p>
// </dd>
//
// <dt class="item title" data-section="title">
// <a class="switch" data-toggle="switch" href="#product_reviews">Reviews</a>
// </dt>
// <dd class="item content" data-section="content">
// <p>It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.</p>
// </dd>
// </dl>
// ```
.example-sections-2 {
.lib-data-tabs(
@_tab-content-border-top-status: true
);
}
// # Accordion
//
// The <code>.lib-data-accordion()</code> mixin is used to setup accordion parameters. Accordion has the same markup as tabs.
//
// ```html
// <dl class="example-sections-3" data-sections="tabs">
// <dt class="item title active" data-section="title">
// <a class="switch" data-toggle="switch" href="#product.info.description">Details</a>
// </dt>
// <dd class="item content active" data-section="content">
// <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book.</p>
// </dd>
// <dt class="item title" data-section="title">
// <a class="switch" data-toggle="switch" href="#product_tags">Tags</a>
// </dt>
// <dd class="item content" data-section="content">
// <p>It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged.</p>
// </dd>
//
// <dt class="item title" data-section="title">
// <a class="switch" data-toggle="switch" href="#product_reviews">Reviews</a>
// </dt>
// <dd class="item content" data-section="content">
// <p>It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.</p>
// </dd>
// </dl>
// ```
.example-sections-3 {
.lib-data-accordion();
}
// # Accordion mixin variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Global variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_accordion-control-font-family</th>
// <td>@accordion-control__font-family</td>
// <td class="vars_value">@tab-control__font-family</td>
// <td class="vars_value" nowrap>'' | false | value</td>
// <td>Accordion font family</td>
// </tr>
// <tr>
// <th>@_accordion-control-font-size</th>
// <td>@accordion-control__font-size</td>
// <td class="vars_value">@font-size__l</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion font size</td>
// </tr>
// <tr>
// <th>@_accordion-control-font-style</th>
// <td>@accordion-control__font-style</td>
// <td class="vars_value">@tab-control__font-style</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion font style</td>
// </tr>
// <tr>
// <th>@_accordion-control-font-weight</th>
// <td>@accordion-control__font-weight</td>
// <td class="vars_value">@tab-control__font-weight</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion font weight</td>
// </tr>
// <tr>
// <th>@_accordion-control-line-height</th>
// <td>@accordion-control__line-height</td>
// <td class="vars_value">@accordion-control__height</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion line height</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Accordion tabs controls settings</th>
// </tr>
// <tr>
// <th>@_accordion-control-border-top</th>
// <td>@accordion-control__border-top</td>
// <td class="vars_value">@tab-control__border-width solid @tab-control__border-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion control border</td>
// </tr>
// <tr>
// <th>@_accordion-control-border-right</th>
// <td>@accordion-control__border-right</td>
// <td class="vars_value">@tab-control__border-width solid @tab-control__border-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion control border</td>
// </tr>
// <tr>
// <th>@_accordion-control-border-bottom</th>
// <td>@accordion-control__border-bottom</td>
// <td class="vars_value">@tab-control__border-width solid @tab-control__border-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion control border</td>
// </tr>
// <tr>
// <th>@_accordion-control-border-left</th>
// <td>@accordion-control__border-left</td>
// <td class="vars_value">@tab-control__border-width solid @tab-control__border-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion control border</td>
// </tr>
// <tr>
// <th>@_accordion-control-background-color</th>
// <td>@accordion-control__background-color</td>
// <td class="vars_value">@tab-control__background-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion control background</td>
// </tr>
// <tr>
// <th>@_accordion-control-color</th>
// <td>@accordion-control__color</td>
// <td class="vars_value">@tab-control__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion control color</td>
// </tr>
// <tr>
// <th>@_accordion-control-text-decoration</th>
// <td>@accordion-control__text-decoration</td>
// <td class="vars_value">@tab-control__text-decoration</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion control text decoration</td>
// </tr>
// <tr>
// <th>@_accordion-control-color-visited</th>
// <td>@accordion-control__color</td>
// <td class="vars_value">@accordion-control__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion control visited link color</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_accordion-control-text-decoration-visited</th>
// <td>@accordion-control__text-decoration</td>
// <td class="vars_value">@accordion-control__text-decoration</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion control visited link text-decoration</td>
// </tr>
// <tr>
// <th>@_accordion-control-background-color-hover</th>
// <td>@accordion-control__hover__background-color</td>
// <td class="vars_value">@tab-control__hover__background-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Hovered accordion control background</td>
// </tr>
// <tr>
// <th>@_accordion-control-color-hover</th>
// <td>@accordion-control__hover__color</td>
// <td class="vars_value">@tab-control__hover__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Hovered accordion control text color</td>
// </tr>
// <tr>
// <th>@_accordion-control-text-decoration-hover</th>
// <td>@accordion-control__hover__text-decoration</td>
// <td class="vars_value">@tab-control__hover__text-decoration</td>
// <td class="vars_value">'' | false | value</td>
// <td>Hovered accordion control text-decoration</td>
// </tr>
// <tr>
// <th>@_accordion-control-background-color-active</th>
// <td>@accordion-control__active__background-color</td>
// <td class="vars_value">@tab-control__active__background-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Active accordion control background</td>
// </tr>
// <tr>
// <th>@_accordion-control-color-active</th>
// <td>@accordion-control__active__color</td>
// <td class="vars_value">@tab-control__active__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Active accordion control text color</td>
// </tr>
// <tr>
// <th>@_accordion-control-text-decoration-active</th>
// <td>@accordion-control__active__text-decoration</td>
// <td class="vars_value">@tab-control__active__text-decoration</td>
// <td class="vars_value">'' | false | value</td>
// <td>Active accordion control text-decoration</td>
// </tr>
// <tr>
// <th>@_accordion-control-height</th>
// <td>@accordion-control__height</td>
// <td class="vars_value">@indent__xl</td>
// <td class="vars_value">'' | false | value</td>
// <td>Height of accordion control</td>
// </tr>
// <tr>
// <th>@_accordion-control-margin-bottom</th>
// <td>@accordion-control__margin-bottom</td>
// <td class="vars_value">@indent__xs</td>
// <td class="vars_value">'' | false | value</td>
// <td>Bottom margin of the accordion control</td>
// </tr>
// <tr>
// <th>@_accordion-control-padding-top</th>
// <td>@accordion-control__padding-top</td>
// <td class="vars_value">@tab-control__padding-top</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion tab control padding top</td>
// </tr>
// <tr>
// <th nowrap="nowrap">@_accordion-control-padding-right</th>
// <td>@accordion-control__padding-right</td>
// <td class="vars_value">@indent__base</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion tab control padding right</td>
// </tr>
// <tr>
// <th>@_accordion-control-padding-bottom</th>
// <td>@accordion-control__padding-bottom</td>
// <td class="vars_value">@tab-control__padding-bottom</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion tab control padding bottom</td>
// </tr>
// <tr>
// <th>@_accordion-control-padding-left</th>
// <td>@accordion-control__padding-left</td>
// <td class="vars_value">@accordion-control__padding-right</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion tab control padding left</td>
// </tr>
// <tr>
// <th colspan="5" class="vars_section">Accordion content settings</th>
// </tr>
// <tr>
// <th>@_accordion-content-background-color</th>
// <td>@accordion-content__background-color</td>
// <td class="vars_value">@tab-control__active__background-color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion tab content background</td>
// </tr>
// <tr>
// <th>@_accordion-content-border</th>
// <td>@accordion-content__border</td>
// <td class="vars_value">@tab-content__border</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion tab content border</td>
// </tr>
// <tr>
// <th>@_accordion-content-margin</th>
// <td>@accordion-content__margin</td>
// <td class="vars_value">0 0 @indent__xs</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion tab content margin</td>
// </tr>
// <tr>
// <th>@_accordion-content-padding</th>
// <td>@accordion-content__padding</td>
// <td class="vars_value">@tab-content__padding-top @tab-content__padding-right @tab-content__padding-bottom @tab-content__padding-left</td>
// <td class="vars_value">'' | false | value</td>
// <td>Accordion tab content padding</td>
// </tr>
// </table>
// </pre>
// # Responsive tabs
//
// Since tabs and accordion have same markup, they can transform one into other by means of CSS and JavaScript. This can be used for responsive web design. For instance, for mobile version there is an accordion, for desktop version it is transformed to tabs. To implement this approach, use the <code>.lib-data-accordion()</code> mixin for mobile version, and the <code>.lib-data-tabs()</code> mixin for desktop version.
//
// ```html
// <dl class="example-sections-4" data-sections="tabs">
// <dt class="item title active" data-section="title">
// <a class="switch" data-toggle="switch" href="#product.info.description">Details</a>
// </dt>
// <dd class="item content active" data-section="content">
// <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book.</p>
// </dd>
// <dt class="item title" data-section="title">
// <a class="switch" data-toggle="switch" href="#product_tags">Tags</a>
// </dt>
// <dd class="item content" data-section="content">
// <p>It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged.</p>
// </dd>
//
// <dt class="item title" data-section="title">
// <a class="switch" data-toggle="switch" href="#product_reviews">Reviews</a>
// </dt>
// <dd class="item content" data-section="content">
// <p>It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.</p>
// </dd>
// </dl>
// ```
@media only screen and (max-width: 99999px) {
.example-sections-4 {
.lib-data-tabs();
}
}
@media only screen and (max-width: @screen__m) {
.example-sections-4 {
.lib-data-accordion();
}
}
// # Tabs Base
//
// The <code>.lib-data-tabs__base()</code> mixin sets basic tabs styles.
//
// ```html
// <dl class="example-sections-5" data-sections="tabs">
// <dt class="item title active" data-section="title">
// <a class="switch" data-toggle="switch" href="#">Details</a>
// </dt>
// <dd class="item content active" data-section="content">
// <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book.</p>
// </dd>
//
// <dt class="item title" data-section="title">
// <a class="switch" data-toggle="switch" href="#">Tags</a>
// </dt>
// <dd class="item content" data-section="content">
// <p>It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged.</p>
// </dd>
//
// <dt class="item title" data-section="title">
// <a class="switch" data-toggle="switch" href="#">Reviews</a>
// </dt>
// <dd class="item content" data-section="content">
// <p>It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.</p>
// </dd>
// </dl>
// ```
.example-sections-5 {
.lib-data-tabs__base();
}
// # Accordion Base
//
// The <code>.lib-data-accordion__base()</code> mixin sets basic accordion styles.
// Data accordion uses the same markup as data tabs.
//
// ```html
// <dl class="example-sections-6" data-sections="tabs">
// <dt class="item title active" data-section="title">
// <a class="switch" data-toggle="switch" href="#">Details</a>
// </dt>
// <dd class="item content active" data-section="content">
// <p>Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book.</p>
// </dd>
// <dt class="item title" data-section="title">
// <a class="switch" data-toggle="switch" href="#">Tags</a>
// </dt>
// <dd class="item content" data-section="content">
// <p>It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged.</p>
// </dd>
//
// <dt class="item title" data-section="title">
// <a class="switch" data-toggle="switch" href="#">Reviews</a>
// </dt>
// <dd class="item content" data-section="content">
// <p>It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.</p>
// </dd>
// </dl>
// ```
.example-sections-6 {
.lib-data-accordion__base();
}
File diff suppressed because it is too large Load Diff
+195
View File
@@ -0,0 +1,195 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
// # Tooltips
//
// Magento UI library provides 4 tooltip types:
// ```css
// top
// bottom
// left
// right
// ```
//
// ```html
//Lorem Ipsum is simply <span class="example-tooltip-bottom"><a href="#" aria-describedby="tooltip-1">dummy</a><span class="tooltip-content" id="tooltip-1" role="tooltip">Lorem Ipsum has been the industry's standard dummy text ever since the 1500s</span></span> text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a <span class="example-tooltip-left"><a href="#" aria-describedby="tooltip-2">galley</a><span class="tooltip-content" id="tooltip-2" role="tooltip">Lorem Ipsum has been the industry's standard dummy text ever since the 1500s</span></span> of type and scrambled it to make a type specimen book. It has survived <span class="example-tooltip-right"><a href="#" aria-describedby="tooltip-3">not</a><span class="tooltip-content" id="tooltip-3" role="tooltip">Lorem Ipsum has been the industry's standard dummy text ever since the 1500s</span></span> only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing <span class="example-tooltip-top"><a href="#" aria-describedby="tooltip-4">software</a><span class="tooltip-content" id="tooltip-4" role="tooltip">Lorem Ipsum has been the industry's standard dummy text ever since the 1500s</span></span> like Aldus PageMaker including versions of Lorem Ipsum.
// ```
.example-tooltip-bottom {
.lib-tooltip(bottom);
}
.example-tooltip-left {
.lib-tooltip(left);
}
.example-tooltip-right {
.lib-tooltip(right);
}
.example-tooltip-top {
.lib-tooltip(top);
}
// # Tooltips variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Global variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_tooltip-position</th>
// <td>-</td>
// <td class="vars_value">top</td>
// <td class="vars_value">top | right | bottom | left</td>
// <td>Side of the element tooltip is displayed on</td>
// </tr>
// <tr>
// <th>@_tooltip-selector-toggle</th>
// <td>-</td>
// <td class="vars_value">~".tooltip-toggle"</td>
// <td class="vars_value">'' | false | value</td>
// <td>The class name of the element that toggles tooltip</td>
// </tr>
// <tr>
// <th>@_tooltip-selector-content</th>
// <td>-</td>
// <td class="vars_value">~".tooltip-content"</td>
// <td class="vars_value">'' | false | value</td>
// <td>The tooltip content class name</td>
// </tr>
// <tr>
// <th>@_tooltip-background</th>
// <td>@tooltip__background</td>
// <td class="vars_value">@color-white</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tooltip background color</td>
// </tr>
// <tr>
// <th>@_tooltip-border-color</th>
// <td>@tooltip__border-color</td>
// <td class="vars_value">#bbb</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tooltip border color</td>
// </tr>
// <tr>
// <th>@_tooltip-border-width</th>
// <td>@tooltip__border-width</td>
// <td class="vars_value">1px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tooltip border width</td>
// </tr>
// <tr>
// <th>@_tooltip-border-radius</th>
// <td>@tooltip__border-radius</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tooltip border radius</td>
// </tr>
// <tr>
// <th>@_tooltip-color</th>
// <td>@tooltip__color</td>
// <td class="vars_value">@primary__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tooltip text color</td>
// </tr>
// <tr>
// <th>@_tooltip-cursor</th>
// <td>@tooltip__cursor</td>
// <td class="vars_value">help</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tooltip cursor</td>
// </tr>
// <tr>
// <th>@_tooltip-font-size</th>
// <td>@tooltip__font-size</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tooltip font size</td>
// </tr>
// <tr>
// <th>@_tooltip-font-family</th>
// <td>@tooltip__font-family</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tooltip font family</td>
// </tr>
// <tr>
// <th>@_tooltip-font-weight</th>
// <td>@tooltip__font-weight</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tooltip font weight</td>
// </tr>
// <tr>
// <th>@_tooltip-font-style</th>
// <td>@tooltip__font-style</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tooltip font style</td>
// </tr>
// <tr>
// <th>@_tooltip-line-height</th>
// <td>@tooltip__line-height</td>
// <td class="vars_value">1.4</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tooltip line height</td>
// </tr>
// <tr>
// <th>@_tooltip-margin</th>
// <td>@tooltip__margin</td>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tooltip margin</td>
// </tr>
// <tr>
// <th>@_tooltip-padding</th>
// <td>@tooltip__padding</td>
// <td class="vars_value">12px 16px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tooltip padding</td>
// </tr>
// <tr>
// <th>@_tooltip-min-width</th>
// <td>@tooltip__min-width</td>
// <td class="vars_value">210px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tooltip minimal width</td>
// </tr>
// <tr>
// <th>@_tooltip-max-width</th>
// <td>@tooltip__max-width</td>
// <td class="vars_value">360px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tooltip maximal width</td>
// </tr>
// <tr>
// <th>@_tooltip-arrow-size</th>
// <td>@tooltip-arrow__size</td>
// <td class="vars_value">5px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tooltip arrow size</td>
// </tr>
// <tr>
// <th>@_tooltip-arrow-offset</th>
// <td>@tooltip-arrow__offset</td>
// <td class="vars_value">10px</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tooltip arrow offset</td>
// </tr>
// <tr>
// <th>@_tooltip-z-index</th>
// <td>@tooltip__z-index</td>
// <td class="vars_value">100</td>
// <td class="vars_value">'' | false | value</td>
// <td>Tooltip z-index</td>
// </tr>
// </table>
// </pre>
File diff suppressed because it is too large Load Diff
+369
View File
@@ -0,0 +1,369 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
// # Utilities
// <code>_utilities.less</code> is a reuseable collection of basic Less mixins.
//
// # .lib-clearfix()
//
// The <code>.lib-clearfix()</code> mixin is a modern solution for healing container`s height which have floated elements. Also its applying prevents top-margins from collapsing.
//
.example-clearfix-container-1 {
border: 1px solid #f00;
}
.example-clearfix-container-2 {
.lib-clearfix();
border: 1px solid #0f0;
}
.example-clearfix-item.left {
float: left;
}
.example-clearfix-item.right {
float: right;
}
// Container with floated child elements without <code>.lib-clearfix()</code>
// ```
// <div class="example-clearfix-container-1">
// <div class="example-clearfix-item left">
// Float left
// </div>
// <div class="example-clearfix-item right">
// Float right
// </div>
// </div>
// ```
// Container with floated child elements with <code>.lib-clearfix()</code>
// ```
// <div class="example-clearfix-container-2">
// <div class="example-clearfix-item left">
// Float left
// </div>
// <div class="example-clearfix-item right">
// Float right
// </div>
// </div>
// ```
// # .lib-visibility-hidden()
//
// The <code>.lib-visibility-hidden()()</code> mixin changes element`s visibility to hidden and height to 0.
//
.example-visibility-hidden {
.lib-visibility-hidden();
}
//
// This is a block with applied <code>.lib-visibility-hidden()</code> mixin.
//
// ```
// <div class="example-visibility-hidden">
// <div>
// This is hidden text
// </div>
// </div>
// ```
// # .lib-visually-hidden()
//
// The <code>.lib-visually-hidden()</code> mixin safely hides the element for accessibility reasons.
//
.example-visually-hidden-1 {
.lib-visually-hidden();
}
//
// This is a block with applied <code>.lib-visually-hidden()</code> mixin.
//
// ```
// <div class="example-visually-hidden-1">
// <div>
// This is hidden text
// </div>
// </div>
// ```
// # .lib-visually-hidden-reset()
//
// The <code>.lib-visually-hidden-reset()</code> mixin resets hidden visibility and makes element again visible.
//
.example-visually-hidden-2 {
background: #fdf0d5;
padding: 5px;
.lib-visually-hidden();
}
.example-visually-hidden-2 {
.lib-visually-hidden-reset();
}
//
// This is a block with applied <code>.lib-visually-hidden-reset()</code> mixin after <code>.lib-visually-hidden()</code> applying.
//
// ```
// <div class="example-visually-hidden-2">
// <div>
// The text is visible again
// </div>
// </div>
// ```
// # .lib-css()
//
// The <code>.lib-css()</code> mixin is used to set any css property if there is a value passed to it by a variable. Also <code>.lib-css()</code> can add -ms-, -webkit- and -moz- prefixes if needed.
//
.example-css-container {
.lib-css(padding, @indent__base);
.lib-css(background, @secondary__color);
}
//
// If the variable is set to <code>false</code>, the <code>.lib-css()</code> mixin will add nothing to the code.
//
// ```
// <div class="example-css-container">
// Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt..
// </div>
// ```
//
.example-css-container-2 {
.lib-css(background, false);
}
// ```
// <div class="example-css-container-2">
// Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt..
// </div>
// ```
//
// # .lib-css() variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Default value </th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_property</th>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Any css property</td>
// </tr>
// <tr>
// <th>@_value</th>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | value</td>
// <td>Any css value</td>
// </tr>
// <tr>
// <th>@_prefix</th>
// <td class="vars_value">0</td>
// <td class="vars_value">'' | false | 1</td>
// <td>If set to "1" adds -ms-, -webkit- and -moz- prefixes to the property</td>
// </tr>
// </table>
// </pre>
// # .lib-rotate()
//
// The <code>.lib-rotate()</code> mixin is a wrapper for css3 transform property with rotate value.
//
.example-rotate {
background: #f00;
position: absolute;
height: 20px;
width: 40px;
.lib-rotate(
@_rotation: 45deg;
);
}
//
// ```
// <div class="example-rotate"></div>
// ```
// # .lib-rotate() variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Default value </th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@rotation</th>
// <td class="vars_value">''</td>
// <td class="vars_value">'' | false | value</td>
// <td>Transform rotate value, false or ''</td>
// </tr>
// </table>
// </pre>
// # .lib-input-placeholder()
//
// The <code>.lib-input-placeholder()</code> mixin is used to change placeholder font-color and font-weight.
//
.example-placeholder {
.lib-input-placeholder(#808080, bold);
}
//
// ```
// <input placeholder="Default text" class="example-placeholder" type="text" />
// ```
//
// # .lib-input-placeholder() variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_input-placeholder-color</th>
// <td class="vars_value">@form-element-input-placeholder__color</td>
// <td class="vars_value">'' | false | value</td>
// <td>Input placeholder color</td>
// </tr>
// <tr>
// <th>@_input-placeholder-font-weight</th>
// <td class="vars_value">@form-element-input__font-weight</td>
// <td class="vars_value">'' | false | value</td>
// <td>Input placeholder font-weight</td>
// </tr>
// </table>
// </pre>
// # .lib-background-gradient()
//
// The <code>.lib-background-gradient()</code> mixin is used for applying custom css3 gradient.
//
.example-background-gradient-1 {
.lib-background-gradient(
@_background-gradient: true,
@_background-gradient-direction: vertical,
@_background-gradient-color-start: #cff,
@_background-gradient-color-end: #ccf
);
}
.example-background-gradient-2 {
.lib-background-gradient(
@_background-gradient: true,
@_background-gradient-direction: horizontal,
@_background-gradient-color-start: #cff,
@_background-gradient-color-end: #ccf
);
}
.example-background-gradient-3-wrapper {
background: #ffc;
padding: 10px;
}
.example-background-gradient-3 {
.lib-background-gradient(
@_background-gradient: true,
@_background-gradient-direction: horizontal,
@_background-gradient-color-start: rgba(255,255,255,0),
@_background-gradient-color-end: #ccf,
@_background-gradient-color-position: false
);
}
//
// ```
// <div class="example-background-gradient-1">
// I`m gradient with vertical direction
// </div>
// ```
//
//
// ```
// <div class="example-background-gradient-2">
// I`m gradient with horizontal direction
// </div>
// ```
//
//
// ```
// <div class="example-background-gradient-3-wrapper">
// <div class="example-background-gradient-3">
// I`m gradient with horizontal direction from transparent to a color
// </div>
// </div>
// ```
//
// # .lib-background-gradient() variables
//
// <pre>
// <table>
// <tr>
// <th class="vars_head">Mixin variable</th>
// <th class="vars_head">Default value</th>
// <th class="vars_head">Allowed values</th>
// <th class="vars_head">Comment</th>
// </tr>
// <tr>
// <th>@_background-gradient</th>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | true</td>
// <td>If set to 'true' the element has gradient background</td>
// </tr>
// <tr>
// <th>@_background-gradient-direction</th>
// <td class="vars_value">''</td>
// <td class="vars_value">'' | horizontal | vertical</td>
// <td>Gradient direction (horizontal or vertical)</td>
// </tr>
// <tr>
// <th>@_background-gradient-color-start</th>
// <td class="vars_value">''</td>
// <td class="vars_value">'' | false | value</td>
// <td>Gradient start color (any css color)</td>
// </tr>
// <tr>
// <th>@_background-gradient-color-end</th>
// <td class="vars_value">''</td>
// <td class="vars_value">'' | false | value</td>
// <td>Gradient end color (any css color) </td>
// </tr>
// <tr>
// <th>@_background-gradient-color-position</th>
// <td class="vars_value">false</td>
// <td class="vars_value">'' | false | true</td>
// <td>Sets the background-color fallback property. When set to 'false', the background-color property will be set to @_background-gradient-color-end. When set to 'true', the background-color property will be set to @_background-gradient-color-start</td>
// </tr>
// </table>
// </pre>
File diff suppressed because it is too large Load Diff
+40
View File
@@ -0,0 +1,40 @@
// /**
// * Copyright © Magento, Inc. All rights reserved.
// * See COPYING.txt for license details.
// */
// # Documentation
// This file was created for documentation generation. It contains includes of all documentation files.
@import '../../source/lib/_lib.less'; // Library files
@import '../../source/_theme.less'; // Theme overrides
@import '../../source/lib/_responsive.less'; // Media queries collector
@baseDir: '/pub/static/frontend/Magento/blank/en_US/';
@import '_actions-toolbar.less';
@import '_breadcrumbs.less';
@import '_buttons.less';
@import '_components.less';
@import '_dropdowns.less';
@import '_forms.less';
@import '_icons.less';
@import '_loaders.less';
@import '_messages.less';
@import '_layout.less';
@import '_pages.less';
@import '_popups.less';
@import '_rating.less';
@import '_resets.less';
@import '_responsive.less';
@import '_sections.less';
@import '_tables.less';
@import '_tooltips.less';
@import '_typography.less';
@import '_utilities.less';
@import '_variables.less';
body {
padding: 15px;
background-image: none;
}
+70
View File
@@ -0,0 +1,70 @@
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
(function () {
'use strict';
$(document)
.on('click.dropdown', function (event) {
if (!$(event.target).is('[data-toggle=dropdown].active, ' +
'[data-toggle=dropdown].active *, ' +
'[data-toggle=dropdown].active + .dropdown-menu, ' +
'[data-toggle=dropdown].active + .dropdown-menu *,' +
'[data-toggle=dropdown].active + [data-target="dropdown"],' +
'[data-toggle=dropdown].active + [data-target="dropdown"] *')
) {
$('[data-toggle=dropdown].active').trigger('close.dropdown');
}
})
.on('keyup.dropdown', function (event) {
if (event.keyCode === 27) { // escape key
$('[data-toggle=dropdown].active').trigger('close.dropdown');
}
});
/** @function dropdown */
$.fn.dropdown = function (options) {
options = $.extend({
parent: null,
btnArrow: '.arrow',
activeClass: 'active'
}, options);
return this.each(function () {
var elem = $(this);
elem.off('open.dropdown, close.dropdown, click.dropdown');
elem.on('open.dropdown', function () {
elem.addClass(options.activeClass)
.parent()
.addClass(options.activeClass);
elem.find(options.btnArrow).text('\u25b2'); // arrow up
});
elem.on('close.dropdown', function () {
elem.removeClass(options.activeClass)
.parent()
.removeClass(options.activeClass);
elem.find(options.btnArrow).text('\u25bc'); // arrow down
});
elem.on('click.dropdown', function () {
var isActive = elem.hasClass('active');
$('[data-toggle=dropdown].active').trigger('close.dropdown');
elem.trigger(isActive ? 'close.dropdown' : 'open.dropdown');
return false;
});
});
};
$(function () {
$('[data-toggle=dropdown]').dropdown();
});
})();