Skip to content

Commit

Permalink
Merge pull request #2 from edwinvanderven/feature/add-prettier
Browse files Browse the repository at this point in the history
Feature/add prettier
  • Loading branch information
edwinvanderven authored Sep 1, 2020
2 parents 588f7ee + 0831a6b commit 5e36640
Show file tree
Hide file tree
Showing 12 changed files with 579 additions and 226 deletions.
22 changes: 22 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Ignore everything but a few: https://stackoverflow.com/a/987162/2725711
# Ignore all
*

# Except for directories
!*/

# Except for specific file types
!*.css
!*.js
!*.json
!*.md
!*.scss
!*.ts
!*.yaml
!*.yml

# Ignore editor specific folder
.vscode

# Ignore imported sources
node_modules/
32 changes: 16 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,27 +39,27 @@ import 'simple-loading-animation/simple-loader.js';

```html
<html>
...
<simple-loader></simple-loader>
...
...
<simple-loader></simple-loader>
...
</html>
```

#### Loading animation with text

The `text` property can be used to show a string to the user while the loading process is commencing.

- Default value for this property is `Loading`.
- Default value for this property is `Loading`.

```sh
import 'simple-loading-animation/simple-loader-with-text.js';
```

```html
<html>
...
<simple-loader-text text="Loading"></simple-loader-text>
...
...
<simple-loader-text text="Loading"></simple-loader-text>
...
</html>
```

Expand All @@ -69,14 +69,14 @@ Using the following css, the loading animations will align inside the center of

```css
.loading-state {
position: absolute;
top: 40%;
bottom: 0;
width: 100%;
text-align: center;
font-family: AvenirNextLTPro-Demi, Helvetica, Arial, sans-serif;
font-size: 18px;
color: #4d4d4d;
position: absolute;
top: 40%;
bottom: 0;
width: 100%;
text-align: center;
font-family: AvenirNextLTPro-Demi, Helvetica, Arial, sans-serif;
font-size: 18px;
color: #4d4d4d;
}
```

Expand All @@ -86,7 +86,7 @@ Don't forget to hide or remove the element again once the loading is done.

For Angular projects you will need to add the custom scheme to support web components.

- See [the Angular documentation](https://angular.io/api/core/CUSTOM_ELEMENTS_SCHEMA)
- See [the Angular documentation](https://angular.io/api/core/CUSTOM_ELEMENTS_SCHEMA)

```js
import { NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
Expand Down
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
@@ -1 +1 @@
export { SimpleLoadingAnimation } from './src/SimpleLoadingAnimation.js';
export { SimpleLoadingAnimation } from './src/SimpleLoadingAnimation.js';
Loading

0 comments on commit 5e36640

Please sign in to comment.