2017 © Pedro Peláez
 

magento2-module module-alpaca-ui-components

Components of the Alpaca theme for Magento 2

image

snowdog/module-alpaca-ui-components

Components of the Alpaca theme for Magento 2

  • Wednesday, August 1, 2018
  • by snowdog
  • Repository
  • 15 Watchers
  • 21 Stars
  • 848 Installations
  • JavaScript
  • 1 Dependents
  • 0 Suggesters
  • 1 Forks
  • 67 Open issues
  • 100 Versions
  • 0 % Grown

The README.md

Greenkeeper badge Browser Status, (*1)

⚠️ This project is deprecated. Please use Alpaca 2.0 instead.


Introduction

Components library of Alpaca design system created to speed up the process of working with design on Magento 2 stores, by creating each UI element, module, and view in a simplified, front-end developer friendly, environment., (*2)

This components liblary is built on top of Fractal.js., (*3)

Magento 2 experience isn't required to work with this code., (*4)

Demo / Preview

https://alpaca-components.now.sh/, (*5)

Installation

  • Install dependencies using yarn
  • Run gulp dev to start Fractal.js development server
  • Run gulp if you want to generate static files (for example to deploy them)

How to create a components library on top of Alpaca

It's necessary only to work outside the Magento. 1. Copy-paste package.json, gulpfile.js, .eslintignore, .eslintrc, .sass-lint.yml, .stylelintrc, .gitignore files to the new project 2. Create modules.json file with an array of paths to parent components libraries. In most cases it will look like this: json ["../../snowdog/module-alpaca-components"] 3. Customize or add new files following the same structure as in Alpaca components library 4. Run gulp dev, (*6)

Directory structure

  • components directory is what you are going to import into the Magento 2 theme.
  • docs and public are just for the local environment purposes, you will find there sample images, testing libs, utility styles etc.

Core concepts

Components architecture

Components are divided into 4 groups: 1. Globals - Contains code that other components can use in any place, for example, typography, icons or SASS variables. 2. Elements - Smallest UI parts, for example, buttons - Element can't depend on other elements - Element shouldn't have any layout 3. Modules - More complex UI parts like search form or header - Takes elements or modules and combine them together adding layout and context 4. Views - Takes elements or modules and combine them together adding final layout and context - You should be able to show it to client/PM as a preview of ready to use store - You shouldn't create any new UI elements, everything needs to be reusable., (*7)

Naming

  • Group name needs to be plural
  • Component name needs to be singular
  • Component name shouldn't be related to any project or place in the layout
    • Bad: filters
    • Good: dropdown-list or collapsible-list
  • Avoid using box, block, item, info, text, cms, especialy combined together, for example info-box
  • Avoid naming two components in similar way i.e. cms-subcategories and cms-subcategory

Colors

  • By default alpaca components uses up to 7 step grayscale

SASS Variables naming

Follow BEM-like naming convention i.e. when you component name is button and you are creating a variable for a padding it should be $button__padding., (*8)

Same as in BEM, you are not allowed to build construction like $button__icon__padding, it should be $button__icon-padding., (*9)

Variables related to the pseudo-classes and pseudo-selectors should be treated as a BEM elements $button__color-hover., (*10)

Also, BEM modificators are allowed in variables $button__padding--secondary, you can even stack them like this $button__padding--secondary--dark., (*11)

To target variable to specific breakpoint adding \@breakpoint at the end of the variable name $button__padding\@medium. Always use small, medium, large etc. to describe the breakpoint., (*12)

Examples of proper variables names:, (*13)

$swatch__option-border
$swatch__option-border-color-hover

$swatch__option-image-height\@large

$swatch__option-size--small
$swatch__option-image-width--small
$swatch__option-image-width--small\@large

Accessibility

You can run gulp a11y to run dev server with accessibility tests enabled., (*14)

If on some view there is no a11y message, please go to the component config and comment out preview: '@docs-only-styles', (*15)

The Versions

01/08 2018

dev-feature/44082

dev-feature/44082

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

30/07 2018

dev-greenkeeper/autoprefixer-9.0.2

dev-greenkeeper/autoprefixer-9.0.2

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

30/07 2018

dev-feature/42596

dev-feature/42596

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

27/07 2018

dev-feature/39906

dev-feature/39906

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

26/07 2018

dev-feature/44067

dev-feature/44067

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

25/07 2018

dev-greenkeeper/stylelint-9.4.0

dev-greenkeeper/stylelint-9.4.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

24/07 2018

dev-feature/375

dev-feature/375

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

23/07 2018

dev-develop

dev-develop

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

23/07 2018

dev-test

dev-test

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

21/07 2018

dev-greenkeeper/autoprefixer-9.0.1

dev-greenkeeper/autoprefixer-9.0.1

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

17/07 2018

dev-greenkeeper/fs-extra-7.0.0

dev-greenkeeper/fs-extra-7.0.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

17/07 2018

dev-greenkeeper/autoprefixer-9.0.0

dev-greenkeeper/autoprefixer-9.0.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

12/07 2018

dev-feature/#42921

dev-feature/#42921

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

09/07 2018

dev-master

9999999-dev

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

09/07 2018

0.7.3

0.7.3.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

06/07 2018

dev-greenkeeper/autoprefixer-8.6.5

dev-greenkeeper/autoprefixer-8.6.5

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

05/07 2018

dev-greenkeeper/gulp-eslint-5.0.0

dev-greenkeeper/gulp-eslint-5.0.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

01/07 2018

dev-feature/391

dev-feature/391

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

26/06 2018

dev-greenkeeper/autoprefixer-8.6.4

dev-greenkeeper/autoprefixer-8.6.4

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

18/06 2018

dev-greenkeeper/autoprefixer-8.6.3

dev-greenkeeper/autoprefixer-8.6.3

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

15/06 2018

dev-greenkeeper/stylelint-9.3.0

dev-greenkeeper/stylelint-9.3.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

12/06 2018

dev-feature/40373

dev-feature/40373

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

09/06 2018

dev-greenkeeper/autoprefixer-8.6.2

dev-greenkeeper/autoprefixer-8.6.2

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

07/06 2018

dev-greenkeeper/autoprefixer-8.6.1

dev-greenkeeper/autoprefixer-8.6.1

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

05/06 2018

dev-feature/40516

dev-feature/40516

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

02/06 2018

dev-greenkeeper/autoprefixer-8.6.0

dev-greenkeeper/autoprefixer-8.6.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

25/05 2018

dev-greenkeeper/autoprefixer-8.5.1

dev-greenkeeper/autoprefixer-8.5.1

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

22/05 2018

dev-greenkeeper/gulp-sass-lint-1.4.0

dev-greenkeeper/gulp-sass-lint-1.4.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

17/05 2018

dev-greenkeeper/update-to-node-10

dev-greenkeeper/update-to-node-10

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

16/05 2018

dev-greenkeeper/stylelint-9.2.1

dev-greenkeeper/stylelint-9.2.1

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

13/05 2018

dev-greenkeeper/autoprefixer-8.5.0

dev-greenkeeper/autoprefixer-8.5.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

10/05 2018

dev-greenkeeper/fs-extra-6.0.1

dev-greenkeeper/fs-extra-6.0.1

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

07/05 2018

0.7.2

0.7.2.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

07/05 2018

dev-release/0.7.2

dev-release/0.7.2

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

07/05 2018

dev-release/0.7.1

dev-release/0.7.1

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

07/05 2018

dev-release/0.7.0

dev-release/0.7.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

01/05 2018

dev-greenkeeper/fs-extra-6.0.0

dev-greenkeeper/fs-extra-6.0.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

28/04 2018

dev-greenkeeper/autoprefixer-8.4.1

dev-greenkeeper/autoprefixer-8.4.1

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

28/04 2018

dev-greenkeeper/autoprefixer-8.4.0

dev-greenkeeper/autoprefixer-8.4.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

16/04 2018

dev-feature/40632

dev-feature/40632

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

16/04 2018

dev-greenkeeper/autoprefixer-8.3.0

dev-greenkeeper/autoprefixer-8.3.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

08/04 2018

dev-greenkeeper/gulp-sass-4.0.1

dev-greenkeeper/gulp-sass-4.0.1

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

05/04 2018

dev-greenkeeper/gulp-sass-4.0.0

dev-greenkeeper/gulp-sass-4.0.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

01/04 2018

dev-greenkeeper/stylelint-9.2.0

dev-greenkeeper/stylelint-9.2.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

30/03 2018

dev-feature/39434

dev-feature/39434

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

30/03 2018

0.6.0

0.6.0.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

06/03 2018

dev-greenkeeper/gulp-notify-3.1.0

dev-greenkeeper/gulp-notify-3.1.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

06/03 2018

dev-revert-324-greenkeeper/stylelint-config-standard-18.2.0

dev-revert-324-greenkeeper/stylelint-config-standard-18.2.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

06/03 2018

dev-greenkeeper/globby-8.0.0

dev-greenkeeper/globby-8.0.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

06/03 2018

dev-greenkeeper/autoprefixer-8.0.0

dev-greenkeeper/autoprefixer-8.0.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

06/03 2018

dev-greenkeeper/gulp-plumber-1.2.0

dev-greenkeeper/gulp-plumber-1.2.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

06/03 2018

dev-feature/39320

dev-feature/39320

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

06/03 2018

dev-greenkeeper/stylelint-8.4.0

dev-greenkeeper/stylelint-8.4.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

06/03 2018

dev-kjugi-patch-1

dev-kjugi-patch-1

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

06/03 2018

dev-greenkeeper/fs-extra-5.0.0

dev-greenkeeper/fs-extra-5.0.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

03/03 2018

dev-greenkeeper/autoprefixer-8.1.0

dev-greenkeeper/autoprefixer-8.1.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

02/03 2018

dev-feature/39330

dev-feature/39330

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

01/03 2018

dev-greenkeeper/stylelint-config-standard-18.2.0

dev-greenkeeper/stylelint-config-standard-18.2.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

28/02 2018

dev-feature/39433

dev-feature/39433

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

28/02 2018

dev-feature/37108

dev-feature/37108

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

28/02 2018

dev-feature/39446

dev-feature/39446

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

21/02 2018

dev-greenkeeper/stylelint-9.1.1

dev-greenkeeper/stylelint-9.1.1

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

21/02 2018

dev-feature/39222

dev-feature/39222

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

21/02 2018

dev-greenkeeper/stylelint-9.1.0

dev-greenkeeper/stylelint-9.1.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

18/02 2018

dev-greenkeeper/stylelint-9.0.0

dev-greenkeeper/stylelint-9.0.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

17/02 2018

dev-greenkeeper/globby-8.0.1

dev-greenkeeper/globby-8.0.1

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

07/02 2018

dev-feature/36863

dev-feature/36863

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

01/02 2018

dev-feature/38538

dev-feature/38538

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

23/01 2018

dev-feature/37752

dev-feature/37752

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

23/01 2018

dev-feature/38277

dev-feature/38277

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

13/01 2018

dev-greenkeeper/gulp-notify-3.2.0

dev-greenkeeper/gulp-notify-3.2.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

11/12 2017

dev-feature/37088

dev-feature/37088

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

30/11 2017

dev-feature/36656

dev-feature/36656

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

30/11 2017

dev-feature/36112

dev-feature/36112

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

30/11 2017

dev-feature/36498

dev-feature/36498

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

30/11 2017

dev-feature/36647

dev-feature/36647

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

29/11 2017

dev-feature/36637

dev-feature/36637

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

29/11 2017

dev-feature/36635

dev-feature/36635

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

29/11 2017

dev-feature/36634

dev-feature/36634

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

29/11 2017

dev-feature/36575

dev-feature/36575

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

29/11 2017

dev-feature/36545

dev-feature/36545

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

23/11 2017

dev-feature/35910

dev-feature/35910

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

20/11 2017

0.5.0

0.5.0.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

17/11 2017

dev-feature/36006

dev-feature/36006

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

13/11 2017

0.4.1

0.4.1.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

13/11 2017

0.4.0

0.4.0.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

06/11 2017

0.3.0

0.3.0.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

04/11 2017

dev-feature/35561

dev-feature/35561

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

30/10 2017

dev-feature/35068

dev-feature/35068

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

30/10 2017

dev-feature/35067

dev-feature/35067

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

30/10 2017

dev-feature/35384

dev-feature/35384

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

30/10 2017

dev-feature/35299

dev-feature/35299

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

30/10 2017

dev-feature/35069

dev-feature/35069

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

30/10 2017

dev-feature/35415

dev-feature/35415

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

28/10 2017

0.2.0

0.2.0.0

Components of the Alpaca theme for Magento 2

  Sources   Download

MIT

27/10 2017

dev-feature/35265

dev-feature/35265

UI Components to Alpaca theme for Magento 2

  Sources   Download

MIT

27/10 2017

dev-feature/35109

dev-feature/35109

UI Components to Alpaca theme for Magento 2

  Sources   Download

MIT

26/10 2017

dev-feature/35010

dev-feature/35010

UI Components to Alpaca theme for Magento 2

  Sources   Download

MIT

23/10 2017

dev-feature/34777

dev-feature/34777

UI Components to Alpaca theme for Magento 2

  Sources   Download

MIT

23/10 2017

dev-feature/32671

dev-feature/32671

UI Components to Alpaca theme for Magento 2

  Sources   Download

MIT