0.0.114 • Published 4 years ago

@miaguila/theme v0.0.114

Weekly downloads
3
License
ISC
Repository
github
Last release
4 years ago

@miaguila/theme

The Mi Aguila Theme Library consists of predefined variables for basic design elements such as color, typography, and spacing. These system properties allow for building layouts and visual styles from defined constraints. This library has to "speak" the same design language as the Design Team resources.

File structure

theme library has 3 main folders: core, common and utils.

npm.io

common: Sometimes there are some simple components that don't need to be a UI Angular component (e.g. links, labels, etc). Designing a UI Angular component could be a long process (e.g. add logic, add different states, unit test, etc) or the component is so simple that it doesn't make sense to turn it into a complex Angular component. As a result of this, the common folder contains the styles of these simple CSS components.

core: It includes all the design basis of Mi Águila:

  • Mi Águila foundations (e.g. color palette, typography, typescale).
  • Utility classes (e.g. bg-dark-snow, w-full, text-left, etc).
  • Global SASS variables (e.g. breakpoint-sm, font-size-base, line-height, etc).

utils: You can find all the global mixins, functions, and so on.

Usage

1. In order to use this library within any Mi Aguila's Web project, you have to install the respective npm package (in this case theme library), running the following command:

npm install @miaguila/theme --save-dev

2. Import the needed library's files on each project's SCSS file that requires the core elements. You could either import the entry point file (@miaguila/theme/base/app.scss) in order to have access to each core element, or just import the specific required file (e.g. variables.scss):

npm.io

npm.io

3. Within the file where you import the theme library resources, you can have access to the variables, utility classes, mixins, etc:

Utility classes

<div class="steps-block">
	<h2 class="title2 text-slate mb-12 text-center">
		Hello world
	</h2>
</div>

Sass variables

// $breakpoint-lg: global responsive breakpoint
.puv-block {
  @media (min-width: $breakpoint-lg) {
    left: 160px;
    top: 45%;
    transform: translate(0px, -50%);
  }
}

Primitive variables (color palette, font size base, etc)

.mac-footer {
  align-items: center;
  background: none;
  border-top: 1px solid var(--default-smoke);
	font-size: var(--font-size-base);
	display: flex;
}

Push and Deploy new features

Whenever someone wants to make a change on the core in theme library, it's needed to follow the bellow steps:

1. Clone the Github project:

git clone [git@github.com:MiAguila/miaguila-kit-theme.git](git@github.com:MiAguila/miaguila-kit-theme.git)

2. The library is within the projects folder

npm.io

3. This project has 2 main branches

master: It's the main branch (it is the Production environment). It's up to date with each library in npm packages repo (https://www.npmjs.com/).

develop: It's the branch where gather all the new features before being approved by the reviewer in order to merge with master branch.

4. Create a new branch from the respective parent branch: For example, If you are going to add or change something in theme library, you should create the new branch from develop.

when you will push your changes, you have to follow the below flow:

(theme)-my-branch → lib-theme → develop → master

  • Make your changes in the new branch (e.g. feature/add-new-color).
  • If everything is Ok (all the test pass, code reviewer approves, etc), make a pull request from feature/add-new-color to develop branch.
  • If everything is Ok (all the test pass, code reviewer approves, etc), make a pull request from develop to master branch.
  • The continuous integration system is going to take the new changes pushed in the master branch, it will auto-increment version number of each library, publish new changes in npm packages repo and deploy it to the storybook environment.
0.0.114

4 years ago

0.0.112

4 years ago

0.0.111

4 years ago

0.0.110

4 years ago

0.0.109

4 years ago

0.0.108

5 years ago

0.0.107

5 years ago

0.0.106

5 years ago

0.0.105

5 years ago

0.0.104

5 years ago

0.0.103

5 years ago

0.0.102

5 years ago

0.0.101

5 years ago

0.0.100

5 years ago

0.0.99

5 years ago

0.0.98

5 years ago

0.0.97

5 years ago

0.0.96

5 years ago

0.0.95

5 years ago

0.0.94

5 years ago

0.0.93

5 years ago

0.0.92

5 years ago

0.0.91

5 years ago

0.0.90

5 years ago

0.0.89

5 years ago

0.0.88

5 years ago

0.0.87

5 years ago

0.0.86

5 years ago

0.0.85

5 years ago

0.0.84

5 years ago

0.0.83

5 years ago

0.0.82

5 years ago

0.0.81

5 years ago

0.0.80

5 years ago

0.0.79

5 years ago

0.0.78

5 years ago

0.0.77

5 years ago

0.0.76

5 years ago

0.0.75

5 years ago

0.0.74

5 years ago

0.0.73

5 years ago

0.0.72

5 years ago

0.0.71

5 years ago

0.0.70

5 years ago

0.0.69

5 years ago

0.0.68

5 years ago

0.0.67

5 years ago

0.0.66

5 years ago

0.0.65

5 years ago

0.0.64

5 years ago

0.0.63

5 years ago

0.0.62

5 years ago

0.0.61

5 years ago

0.0.60

5 years ago

0.0.59

5 years ago

0.0.58

5 years ago

0.0.57

5 years ago

0.0.56

5 years ago

0.0.55

5 years ago

0.0.54

5 years ago

0.0.53

5 years ago

0.0.52

5 years ago

0.0.51

5 years ago

0.0.50

5 years ago

0.0.49

5 years ago

0.0.48

5 years ago

0.0.47

5 years ago

0.0.46

5 years ago

0.0.45

5 years ago

0.0.44

5 years ago

0.0.43

5 years ago

0.0.42

5 years ago

0.0.41

5 years ago

0.0.40

5 years ago

0.0.39

5 years ago

0.0.38

5 years ago

0.0.36

5 years ago

0.0.35

5 years ago

0.0.34

5 years ago

0.0.33

5 years ago

0.0.32

5 years ago

0.0.31

5 years ago

0.0.30

5 years ago

0.0.29

5 years ago

0.0.28

5 years ago

0.0.26

5 years ago

0.0.25

5 years ago

0.0.24

5 years ago

0.0.23

5 years ago

0.0.22

5 years ago

0.0.21

5 years ago

0.0.20

5 years ago

0.0.19

5 years ago

0.0.18

5 years ago

0.0.17

5 years ago

0.0.16

5 years ago

0.0.15

5 years ago

0.0.14

5 years ago