From 07eb5da7eedcdc5d9ebba8384bf43579003b5544 Mon Sep 17 00:00:00 2001 From: BART! Date: Sat, 25 Jul 2020 18:37:34 +0200 Subject: [PATCH] =?UTF-8?q?chore(update):=20beta=20release=202.0.0-beta.1?= =?UTF-8?q?=20=CE=B2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.json | 3 ++- projects/ngx-scrolltop/README.md | 28 ++++++++++++++++++++++++---- projects/ngx-scrolltop/package.json | 2 +- 3 files changed, 27 insertions(+), 6 deletions(-) diff --git a/package.json b/package.json index 26714e5..d5c6e8e 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "ngx-scrolltop", - "version": "1.0.0", + "version": "2.0.0-rc.1", "description": "Lightweight, Material Design inspired button for scroll-to-top of the page. No dependencies. Pure Angular!", "author": "Lukas Bartak (https://github.com/bartholomej)", "scripts": { @@ -14,6 +14,7 @@ "clean:schematics": "rm -rf dist/ngx-scrolltop/schematics/", "deploy:ghpages": "yarn build && yarn build:example && ngh --dir=dist/example", "publish:npmjs": "npm run syncprojects && npm run build && npm publish --folder dist/ngx-scrolltop", + "publish:next": "yarn && yarn syncprojects && yarn build && yarn build:schematics && yarn test --configuration=ci && npm publish --folder dist/ngx-scrolltop --tag next", "gpr:setup": "yarn ts-node --project scripts/tsconfig.ts-node.json scripts/gpr-setup", "test": "ng test", "lint": "ng lint", diff --git a/projects/ngx-scrolltop/README.md b/projects/ngx-scrolltop/README.md index f897085..845cdc6 100644 --- a/projects/ngx-scrolltop/README.md +++ b/projects/ngx-scrolltop/README.md @@ -8,9 +8,11 @@ ![](https://github.com/bartholomej/ngx-scrolltop/workflows/Build%20&%20Tests%20&%20Publish/badge.svg) [![volkswagen status](https://auchenberg.github.io/volkswagen/volkswargen_ci.svg?v=1)](https://github.com/auchenberg/volkswagen) -> Lightweight, **Material Design inspired button for scroll-to-top** of the page. No dependencies. **Pure Angular!** +> Lightweight, **Material Design inspired button for scroll-to-top** of the page. +> No dependencies. +> **Pure Angular!** -> ✓ Angular 10, Ivy and SSR compatible +> ✓ Angular 10, Ivy and Angular Universal (SSR) compatible Just hit the button to smoothly scroll back to the top of the page. [Here's the demo.](http://bartholomej.github.io/ngx-scrolltop/) @@ -102,10 +104,28 @@ In **app.component.html** you just need to add your new button. Usually at the e | **backgroundColor** | string | #212121 | Background color (you can use all values for `backgroud-color` css property). _You can override `theme` color_ | | **symbolColor** | string | #fafafa | Symbol color (you can use all values for `fill` svg property). _You can override `theme` color_ | | **size** | number | 40 | Button size [in pixels]. _(Symbol will be resized automatically_) | -| **symbol** | string | | You can use utf8 chars for customizing symbol. For example: `↑` | +| ~~**symbol**~~ | ~~string~~ | | ~~You can use utf8 chars for customizing symbol. For example: `↑`~~ Removed in v2.0.0. Use _content projection_. See example [here](#symbol) | | **position** | 'left' \| 'right' | 'right' | Left or right, that is the question... | | **theme** | [NgxScrollTopTheme](projects/ngx-scrolltop/src/lib/ngx-scrolltop.interface.ts) | 'gray' | Material color themes | +#### Symbol + +Since version v2.0.0 you can use _content projection_ for your own symbol. + +```html + + ↑ + +``` + +Or you can even use your own components or fonts (e.g. fontAwesome) + +```html + + + +``` + ### Directive | Option | Type | Default | Description | @@ -123,11 +143,11 @@ In **app.component.html** you just need to add your new button. Usually at the e [size]="50" backgroundColor="#33691e" symbolColor="#fff" - symbol="↑" mode="smart" position="left" theme="pink" > + ↑ ``` diff --git a/projects/ngx-scrolltop/package.json b/projects/ngx-scrolltop/package.json index c224fd1..772f742 100644 --- a/projects/ngx-scrolltop/package.json +++ b/projects/ngx-scrolltop/package.json @@ -1,6 +1,6 @@ { "name": "ngx-scrolltop", - "version": "1.0.0", + "version": "2.0.0-rc.1", "description": "Lightweight, Material Design inspired button for scroll-to-top of the page. No dependencies. Pure Angular!", "author": "Lukas Bartak (https://github.com/bartholomej)", "peerDependencies": {