mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ADF-1159] Fix misspellings in .md files (#2124)
This commit is contained in:
committed by
Eugenio Romano
parent
4fd8bfb875
commit
92e30c2fa3
@@ -58,7 +58,7 @@ See it live: [Form Quickstart](https://embed.plnkr.co/YSLXTqb3DtMhVJSqXKkE/)
|
||||
Before you start using this development framework, make sure you have installed all required software and done all the
|
||||
necessary configuration, see this [page](https://github.com/Alfresco/alfresco-ng2-components/blob/master/PREREQUISITES.md).
|
||||
|
||||
> If you plan using this component with projects generated by Angular CLI, please refer to the following article: [Using ADF with Angular CLI](https://github.com/Alfresco/alfresco-ng2-components/wiki/Angular-CLI)
|
||||
> If you plan to use this component with projects generated by Angular CLI, you can read more in [Using ADF with Angular CLI](https://github.com/Alfresco/alfresco-ng2-components/wiki/Angular-CLI)
|
||||
|
||||
## Install
|
||||
|
||||
@@ -133,7 +133,7 @@ The param nameNode is optional.
|
||||
|
||||
**Display form definition by ECM nodeId:**
|
||||
|
||||
In this case the metadata of the node are showed in an activiti Form,
|
||||
In this case the metadata of the node are shown in an activiti Form,
|
||||
and store the form field as metadata. The param nameNode is optional.
|
||||
|
||||
```html
|
||||
@@ -153,11 +153,11 @@ The recommended set of properties can be found in the following table:
|
||||
| --- | --- | --- | --- |
|
||||
| taskId | string | | Task id to fetch corresponding form and values. |
|
||||
| formId | string | | The id of the form definition to load and display with custom values. |
|
||||
| formName | string | | Name of hte form definition to load and display with custom values. |
|
||||
| formName | string | | Name of the form definition to load and display with custom values. |
|
||||
| data | FormValues | | Custom form values map to be used with the rendered form. |
|
||||
| showTitle | boolean | true | Toggle rendering of the form title. |
|
||||
| showCompleteButton | boolean | true | Toggle rendering of the `Complete` outcome button. |
|
||||
| disableCompleteButton | boolean | false | The `Complete` outcome button is showed but it will be disabled. |
|
||||
| disableCompleteButton | boolean | false | The `Complete` outcome button is shown but it will be disabled. |
|
||||
| showSaveButton | boolean | true | Toggle rendering of the `Save` outcome button. |
|
||||
| readOnly | boolean | false | Toggle readonly state of the form. Enforces all form widgets render readonly if enabled. |
|
||||
| showRefreshButton | boolean | true | Toggle rendering of the `Refresh` button. |
|
||||
@@ -183,7 +183,7 @@ The recommended set of properties can be found in the following table:
|
||||
| formLoaded | [FormModel](https://github.com/Alfresco/alfresco-ng2-components/blob/master/ng2-components/ng2-activiti-form/src/components/widgets/core/form.model.ts) | Invoked when form is loaded or reloaded. |
|
||||
| formSaved | [FormModel](https://github.com/Alfresco/alfresco-ng2-components/blob/master/ng2-components/ng2-activiti-form/src/components/widgets/core/form.model.ts) | Invoked when form is submitted with `Save` or custom outcomes. |
|
||||
| formCompleted | [FormModel](https://github.com/Alfresco/alfresco-ng2-components/blob/master/ng2-components/ng2-activiti-form/src/components/widgets/core/form.model.ts) | Invoked when form is submitted with `Complete` outcome. |
|
||||
| formDataRefreshed | [FormModel](https://github.com/Alfresco/alfresco-ng2-components/blob/master/ng2-components/ng2-activiti-form/src/components/widgets/core/form.model.ts) | Invoked when form values are refreshed due a data property change |
|
||||
| formDataRefreshed | [FormModel](https://github.com/Alfresco/alfresco-ng2-components/blob/master/ng2-components/ng2-activiti-form/src/components/widgets/core/form.model.ts) | Invoked when form values are refreshed due to a data property change |
|
||||
| executeOutcome | [FormOutcomeEvent](https://github.com/Alfresco/alfresco-ng2-components/blob/master/ng2-components/ng2-activiti-form/src/components/widgets/core/form-outcome-event.model.ts) | Invoked when any outcome is executed, default behaviour can be prevented via `event.preventDefault()` |
|
||||
| onError | any | Invoked at any error |
|
||||
|
||||
@@ -394,7 +394,7 @@ The result should be as following:
|
||||
|
||||
### Listen all form Events
|
||||
|
||||
If you want listen all the events fired the form you can subscribe to this Subject :
|
||||
If you want to listen all the events fired in the form you can subscribe to this Subject :
|
||||
|
||||
```ts
|
||||
formService.formEvents.subscribe((event: Event) => {
|
||||
@@ -410,7 +410,7 @@ formService.formEvents.subscribe((event: Event) => {
|
||||
|
||||
## Build from sources
|
||||
|
||||
You can build component from sources with the following commands:
|
||||
You can build the component from sources with the following commands:
|
||||
|
||||
```sh
|
||||
npm install
|
||||
|
@@ -2,13 +2,13 @@
|
||||
|
||||
_Note: it is assumed you are familiar with Alfresco Activiti form definition structure._
|
||||
|
||||
- How components and widgets are rendred on a Form
|
||||
- How components and widgets are rendered on a Form
|
||||
- Replacing default form widgets with custom components
|
||||
- Replacing custom stencils with custom components
|
||||
|
||||
|
||||
|
||||
## How components and widgets are rendred on a Form
|
||||
## How components and widgets are rendered on a Form
|
||||
|
||||
All form field editors (aka widgets) on a Form are rendered by means of `FormFieldComponent`
|
||||
that takes an instance of a `FormFieldModel`:
|
||||
@@ -35,7 +35,7 @@ It can be either a predefined component type or a dynamically evaluated based on
|
||||
|
||||
#### Static component mapping
|
||||
|
||||
You can (re)map fields like following:
|
||||
You can (re)map fields like in the following:
|
||||
|
||||
```ts
|
||||
let customResolver: ComponentTypeResolver = () => CustomWidgetComponent;
|
||||
@@ -112,7 +112,7 @@ import { WidgetComponent } from 'ng2-activiti-form';
|
||||
export class CustomEditorComponent extends WidgetComponent {}
|
||||
```
|
||||
|
||||
Now you will need adding it to the application module or any custom module that is imported into the application one:
|
||||
Now you will need to add it to the application module or any custom module that is imported into the application one:
|
||||
|
||||
```ts
|
||||
import { NgModule } from '@angular/core';
|
||||
@@ -128,8 +128,8 @@ export class CustomEditorsModule {}
|
||||
|
||||
Every custom widget should be added into all three module collections: `declarations`, `exports` and `entryComponents`.
|
||||
|
||||
If you decided storing custom widgets in a separate dedicated module (and optionally as separate redistributable library)
|
||||
don't forget importing it into your main application one:
|
||||
If you decided to store custom widgets in a separate dedicated module (and optionally as separate redistributable library)
|
||||
don't forget to import it into your main application one:
|
||||
|
||||
```ts
|
||||
@NgModule({
|
||||
@@ -194,7 +194,7 @@ Once wired with a new task it should look like the following within Alfresco Act
|
||||
|
||||
### Creating custom widget
|
||||
|
||||
If you load previously created task into ADF `<actiiti-form>` component you will see something like the following:
|
||||
If you load previously created task into ADF `<activiti-form>` component you will see something like the following:
|
||||
|
||||

|
||||
|
||||
@@ -256,6 +256,6 @@ export class MyView {
|
||||
}
|
||||
```
|
||||
|
||||
At the runtime you should now see your custom Angular 2 component rendered in place of the stencils:
|
||||
At runtime you should now see your custom Angular 2 component rendered in place of the stencils:
|
||||
|
||||

|
@@ -105,7 +105,7 @@ class SampleClass1 implements OnInit {
|
||||
### Mapping template with component class
|
||||
|
||||
In order to map **form runtime template** with the corresponding component class
|
||||
you will need registering both parts with `adf.registerComponent(identifier, class)` api:
|
||||
you will need to register both parts with `adf.registerComponent(identifier, class)` api:
|
||||
|
||||
```js
|
||||
if (adf) {
|
||||
|
Reference in New Issue
Block a user