This is the demo and developing environment for Knora ui modules.
Knora itself is a software framework for storing, sharing, and working with primary sources and data in the humanities.
This version of Knora-ui requires Knora v2.2.0-snapshot (pre-release) or later.
Already published modules
The core module contains every service to use Knora's RESTful webapi.
The authentication module contains the login form (for standalone usage) or a complete login- / logout-button environment incl. the login form.
Search module allows to make simple searches or extended searches in Knora. In extended search, resource class and its properties related to one specific ontology are selected to create your query.
The viewer module contains object components to show the resource class representations from Knora, the gui-elements for the property values and different kind of view frameworks.
The action module contains special buttons (e.g. to sort a list), pipes and directives.
Good news: Angular 6 has a built-in library support. Previous we built the library with the following setup:
We used ng-packagr by following the ng-packaged-example and this tutorial: https://medium.com/@nikolasleblanc/building-an-angular-4-component-library-with-the-angular-cli-and-ng-packagr-53b2ade0701e
Now we can create a library module quite easy. Please use the following command schema:
$ ng generate library @knora/[module-name] --prefix=kui
If you want to add more components, services and so on to this library, you can do it with:
$ ng generate component [path/in/your/module/][name-of-component] --project @knora/[module-name]
It puts the component or the service into
lib/ directly. Otherwise you can define a path inside of
Install the demo app
$ cd knora-ui $ yarn install --prod=false $ rm -rf dist/@knora $ yarn build-lib
To create new e.g. component inside existing module use the following command:
$ ng g c [component-name] --project @knora/[module-name] --styleext scss
Knora module structure
- services (for API requests)
- constants & utils (to work with Knora)
- buttons & buttons
- directives & pipes
- search results
- search panel incl. search action (like adding a collection)
- object viewer (incl. video, audio, image)
- properties (as form elements)
Required version of Knora
3.0.0 or later