@oncehub/knowledgeowl-angular 4.1.8 → 4.1.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +109 -3
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -1,5 +1,111 @@
1
- # KnowledgeOwl Angular
1
+ # knowledgeowl-angular
2
2
 
3
- The sources for this package are in the main [KnowledgeOwl Angular](https://github.com/scheduleonce/knowledgeowl-angular) repo. Please file issues and pull requests against that repo.
3
+ [![Build status](https://github.com/scheduleonce/knowledgeowl-angular/actions/workflows/node.js.yml/badge.svg)](https://github.com/scheduleonce/knowledgeowl-angular/actions)
4
4
 
5
- License: MIT
5
+ Project that enables angular application to integrate KnowledgeOwl widget. This gives following features:
6
+
7
+ 1. Integrate KnowledgeOwl angular widget into application.
8
+ 2. Link HTML element to KnowledgeOwl article.
9
+
10
+ ## How to install?
11
+
12
+ You can use npm command line tool to install package.
13
+
14
+ ```sh
15
+ npm install @oncehub/knowledgeowl-angular
16
+ ```
17
+
18
+ ## How to use?
19
+
20
+ Import the Module:
21
+
22
+ ```sh
23
+ import {KnowledgeOwlWidgetModule, KnowledgeOwlLinkModule} from '@oncehub/knowledgeowl-angular';
24
+
25
+ @NgModule({
26
+ ...
27
+ imports: [KnowledgeOwlWidgetModule, KnowledgeOwlLinkModule],
28
+ providers: [{provide: 'KOProjectURL', useValue: 'https://knowledgeowlurl.com'}]
29
+ ...
30
+ })
31
+ export class AppModule { }
32
+ ```
33
+
34
+ Add widget in app.component.html
35
+
36
+ ```sh
37
+ <knowledge-owl-widget
38
+ [projectKey]="'projectKeyProvidedByKnowledgeOwl'"
39
+ ></knowledge-owl-widget>
40
+ ```
41
+
42
+ ## How to link article to `<a>` or `button`?
43
+
44
+ ```sh
45
+ <a knowledgeOwlLink="test-article"></a>
46
+ ```
47
+
48
+ ## Directives
49
+
50
+ ### `KnowledgeOwlWidget`
51
+
52
+ Selector: `knowledge-owl-widget`
53
+
54
+ Exported as: `knowledgeOwlWidget`
55
+
56
+ ## Properties
57
+
58
+ | Name | Required | Description |
59
+ | ------------------------------------ | -------- | ---------------------------------------------- |
60
+ | @Input() <br/>`projectKey: string` | true | Product key to access KnowledgeOwl widget |
61
+ | @Input() <br/>`pageLocation: string` | false | Page location of application. Example "\start" |
62
+
63
+ ### Open the widget programmatically
64
+
65
+ The widget exposes an API to open/close programmatically.
66
+
67
+ ```sh
68
+ class MyComponent {
69
+ @ViewChild(KnowledgeOwlWidget) widget: KnowledgeOwlWidget;
70
+
71
+ someMethod() {
72
+ this.widget.open();
73
+ }
74
+ }
75
+ ```
76
+
77
+ ### Open the article in widget programmatically
78
+
79
+ The widget exposes an API to open/close widget with article programmatically.
80
+
81
+ ```sh
82
+ class MyComponent {
83
+ @ViewChild(KnowledgeOwlWidget) widget: KnowledgeOwlWidget;
84
+
85
+ someMethod() {
86
+ this.widget.open('article-name');
87
+ }
88
+ }
89
+ ```
90
+
91
+ ## Directives
92
+
93
+ ### `KnowledgeOwlLink`
94
+
95
+ Selector: `knowledgeOwlLink`
96
+
97
+ Exported as: `knowledgeOwlLink`
98
+
99
+ ## Properties
100
+
101
+ | Name | Required | Description |
102
+ | ---------------------------------------- | -------- | ------------------------- |
103
+ | @Input() <br/>`knowledgeOwlLink: string` | true | KnowledgeOwl Article Name |
104
+
105
+ ### Development
106
+
107
+ Package is automatically pushed to npm when [creating a new release](.github/workflows/npm-publish.yml) on Github. Check out the release section in the repo. Read more about releases [here](https://docs.github.com/en/repositories/releasing-projects-on-github/managing-releases-in-a-repository).
108
+
109
+ ### License
110
+
111
+ This module is licensed under the MIT License. See the LICENSE file for details.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@oncehub/knowledgeowl-angular",
3
3
  "description": "KnowledgeOwl widget integration for Angular",
4
- "version": "4.1.8",
4
+ "version": "4.1.11",
5
5
  "author": "https://github.com/scheduleonce/knowledgeowl-angular/graphs/contributors",
6
6
  "repository": {
7
7
  "type": "git",