Skip to content
This repository has been archived by the owner on Jun 26, 2020. It is now read-only.

Commit

Permalink
Docs: Minor corrections.
Browse files Browse the repository at this point in the history
  • Loading branch information
oleq committed Jan 24, 2020
1 parent 4674ba4 commit b488001
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
3 changes: 2 additions & 1 deletion src/view/styles/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,8 @@ export function getBoxSidesValueReducer( styleShorthand ) {
}

/**
* Returns a proper 1-to-4 value of a CSS [shorthand](https://developer.mozilla.org/en-US/docs/Web/CSS/Shorthand_properties) notation.
* Returns a [shorthand](https://developer.mozilla.org/en-US/docs/Web/CSS/Shorthand_properties) notation
* of a CSS property value.
*
* getBoxSidesShorthandValue( { top: '1px', right: '1px', bottom: '2px', left: '1px' } );
* // will return '1px 1px 2px'
Expand Down
12 changes: 10 additions & 2 deletions src/view/stylesmap.js
Original file line number Diff line number Diff line change
Expand Up @@ -887,14 +887,22 @@ function appendStyleValue( stylesObject, nameOrPath, valueOrObject ) {
*/

/**
* An object describing box sides values.
* An object describing values associated with the sides of a box, for instance margins, paddings,
* border widths, border colors, etc.
*
* const margin = {
* top: '1px',
* right: '3px',
* bottom: '3px',
* left: '7px'
* }
* };
*
* const borderColor = {
* top: 'red',
* right: 'blue',
* bottom: 'blue',
* left: 'red'
* };
*
* @typedef {Object} module:engine/view/stylesmap~BoxSides
*
Expand Down

0 comments on commit b488001

Please sign in to comment.