[ADF-3745] Reviewed breaking changes page (#4320)

* [ADF-3745] Reviewed breaking changes page

* [ADF-3745] Added link to breaking changes in doc index page
This commit is contained in:
Andy Stark
2019-02-14 16:26:22 +00:00
committed by Mario Romano
parent 819e03d535
commit 9792fd2390
2 changed files with 141 additions and 46 deletions

View File

@@ -36,6 +36,8 @@ A few other pages of information are also available:
contains a preview of features we hope to release in future versions of ADF. contains a preview of features we hope to release in future versions of ADF.
- The [License info](license-info/license-info-v3.0.0.md) section lists the third-party - The [License info](license-info/license-info-v3.0.0.md) section lists the third-party
libraries used by ADF along with links to their Open Source licenses. libraries used by ADF along with links to their Open Source licenses.
- The [Breaking changes](breaking-changes/breaking-change-2.6.0-3.0.0.md) section lists
all breaking changes between major versions, such as removal of deprecated items.
## Contents ## Contents

View File

@@ -1,55 +1,148 @@
This document will list all the ADF 2.X component deprecated that has been removed in the 3.0 version : ---
Title: Breaking changes, 2.6.0 -> 3.0.0
---
# Breaking changes, 2.6.0 -> 3.0.0
This document lists all the deprecated ADF v2.x components that were removed for v3.0.0:
- [PR ADF-3354](https://github.com/Alfresco/alfresco-ng2-components/pull/3980) The adf-accordion component has been removed ```html <adf-accordion> <adf-accordion-group> ``` use the angular Material expansion and refer to the [official material documentation](https://material.angular.io/components/expansion/api) - [PR ADF-3354](https://github.com/Alfresco/alfresco-ng2-components/pull/3980):
The `adf-accordion` component has been removed.
- [PR ADF-3746](https://github.com/Alfresco/alfresco-ng2-components/pull/3975) In order to not let our ADF style classes mix with other project a new style lint rules have been added. This rule enforce the use of the **adf-** prefix in all our classes. Please refer to the PR to see the list of the all style changed. If you where rewriting any ADF classes without the **adf-** prefix you will need to fix it. For example now ```css .card-view ``` is ```css .adf-card-view ``` ```html
<adf-accordion>
<adf-accordion-group>
...
```
- [PR ADF-1443](https://github.com/Alfresco/alfresco-ng2-components/pull/4028) ```js DownloadZipDialogComponent ``` and ```js NodeDownloadDirective ``` has been moved from the content service to the core module. This modify has allowed to remove some code duplication present in both modules Use the Angular Material [Expansion Panel](https://material.angular.io/components/expansion/api)
as an alternative.
- [PR ADF-1873](https://github.com/Alfresco/alfresco-ng2-components/pull/4145) - [PR ADF-3746](https://github.com/Alfresco/alfresco-ng2-components/pull/3975): In order to
- ```html adf-search-control``` **SearchControlComponent** **QueryBody**, **customQueryBody** input parameter has been removed in favor of the [custom service search](https://github.com/Alfresco/alfresco-ng2-components/blob/ad5dcfe7c3449f74ac4097bbfc44f490b81f5ce1/docs/core/search-configuration.interface.md). deprecated in 2.1.0 prevent our ADF style classes interfering with other projects, a new set of style lint rules has
- ```html <adf-viewer>``` **fileNodeId** Node Id of the file to load has been renamed in **nodeId** been added. These rules enforce the use of the **adf-** prefix in all our classes. Please refer
- ```html <adf-viewer>``` **allowShare** has been removed as parameter if you want archive this button. Inject the [Share Directive](https://github.com/Alfresco/alfresco-ng2-components/blob/9915935714d7e39acd67ce5121e01051162058d6/docs/content-services/content-node-share.directive.md) in the [custom toolbar](https://github.com/Alfresco/alfresco-ng2-components/blob/9915935714d7e39acd67ce5121e01051162058d6/docs/core/viewer.component.md#custom-toolbar) to the PR to see the list of the all styles that were changed. If you have been rewriting any ADF
- ```html <adf-viewer>``` **allowSidebar** is now **allowLeftSidebar** and **allowRightSidebar** classes without the **adf-** prefix, you will now need to update them. For example, `.card-view`
- ```html <adf-viewer>``` **showSidebar** is now **showLeftSidebar** and **showRightSidebar** is now `.adf-card-view`.
- ```html <adf-viewer>``` **sidebarTemplate** is now **sidebarLeftTemplate** and **sidebarRightTemplate**
- ```html <adf-viewer>``` **sidebarPosition** has been removed not needed anymore you can now have two sidebar left and right at the same time. - [PR ADF-1443](https://github.com/Alfresco/alfresco-ng2-components/pull/4028): `DownloadZipDialogComponent`
- ```html analytics-report-list``` is now ```html adf-analytics-report-list``` and `NodeDownloadDirective` have been moved from the Content Services module to the Core module.
- ```html analytics-report-parameters``` is now ```html adf-analytics-report-parameters``` This modification has enabled us to remove some code duplication between the two modules.
- ```CommentProcessModel``` was moved in the core under the name of ```CommentModel``` in 2.3.0 now is only possible to import it from **coreModule**
- ```CommentsModule CommentListComponent CommentsComponent ``` are not exported anymore from **ProcessModule** but form **coreModule** (deprecated in 2.3.0 ) - [PR ADF-1873](https://github.com/Alfresco/alfresco-ng2-components/pull/4145):
- ```html <adf-upload-drag-arear>``` **parentId** has been renamed in ***rootFolderId** was already deprecated in 2.4.0 - `adf-search-control`: The `QueryBody`, and
- UploadBase service createFolder event emitted when a folder was created deprecated in 2.4.0 is no longer used by the framework use the **success** event `customQueryBody` inputs of the `SearchControlComponent` have been removed in favor of the
- ```html <adf-filters>``` is now ```html <adf-task-filters>``` deprecated in 2.4.0 [custom search configuration interface](../core/search-configuration.interface.md).
- ```html adf-restore``` deprecated in 2.4.0 has been removed because not properly working. A new feature to properly implement this functionality has been created [ADF-3901](https://issues.alfresco.com/jira/browse/ADF-3901) The inputs were deprecated in v2.1.0.
- ```html <adf-form>``` event **onError** Emitted when any error occurs deprecated in 2.4.0, has been renamed as **error** - `<adf-viewer>`: The `fileNodeId` input that supplies the Node Id of the file to
- ```html context-menu-holder ``` is now ```html adf-context-menu-holder ``` load has been renamed as `nodeId`.
- ```js file-draggable ```/Emitted when one or more files are dragged and dropped onto the draggable element. @deprecated in 2.4.0: use `filesDropped` instead */ @Output() filesEntityDropped: EventEmitter<any> = new EventEmitter(); - `<adf-viewer>`: The `allowShare` input has been removed. Inject the
- ```js DocumentListService.hasPermission``` duplicated method has been removed use ```js ContentService.hasAllowableOperations``` [Share Directive](../content-services/content-node-share.directive.md) in a
- ```html diagram-sequence-flow``` tag renamed in ```html 'adf-diagram-sequence-flow ``` @deprecated 2.3.0 [custom toolbar](../core/viewer.component.md#custom-toolbar) to recreate the behavior of the
- ```html diagram-alfresco-publish-task``` tag renamed in ```html 'adf-diagram-publish-task ``` @deprecated 2.3.0 Share button.
- ```html <adf-login>``` disableCsrf input has been removed use the app.config.json disableCsrf property - `<adf-viewer>`: The `allowSidebar` input has now been split into `allowLeftSidebar` and `allowRightSidebar`.
- ```html <adf-login>``` providers input has been removed use the app.config.json providers property - `<adf-viewer>`: The `showSidebar` input has now been split into `showLeftSidebar` and `showRightSidebar`.
- ```html <adf-document-list>``` skipCount has been removed define it in pagination using the pageSize - `<adf-viewer>`: The `sidebarTemplate` input has now been split into `sidebarLeftTemplate` and
- ```html <adf-document-list>``` enableInfiniteScrolling has been removed it wasn't used anymore to choose the right pagination strategy add the infinite pagination or the normal pagination add assign as target your document list. `sidebarRightTemplate`.
- ```html <adf-document-list>``` folderNode has been removed use **currentFolderId** and **node** - `<adf-viewer>`: The `sidebarPosition` input has been removed since it is not needed anymore
- ```js SettingsService``` has been removed deprecated in 1.7.0 (you can now have two sidebars on the left and right at the same time).
- ```js FormService``` ```js addFieldsToAForm(formId: string, formModel: FormDefinitionModel) ``` has been removed - `analytics-report-list` is now `adf-analytics-report-list`.
- ```html <file-uploading-dialo>``` has been renamed to ```html <adf-file-uploading-dialog> ``` - `analytics-report-parameters` is now `adf-analytics-report-parameters`.
- `CommentProcessModel` was moved into the Core library with the name `CommentModel` in v2.3.0. Now you
can only import it from `CoreModule`.
- `CommentsModule`, `CommentListComponent`, and `CommentsComponent` are no longer exported from
`ProcessModule` but now from `CoreModule`. The old usage was deprecated in v2.3.0.
- `<adf-upload-drag-area>`: The `parentId` input has been renamed as `rootFolderId`. The old
name was deprecated in v2.4.0.
- The `createFolder` event of the `UploadBase` class (emitted when a folder was
created) was deprecated in v2.4.0 and is no longer used by the framework
Use the `success` event instead.
- `<adf-filters>` is now `<adf-task-filters>`. The old usage was deprecated in v2.4.0.
- `adf-restore`, which was deprecated in v2.4.0, has been removed because it was not
working properly. A new feature to implement this functionality correctly has
been created. See [ADF-3901](https://issues.alfresco.com/jira/browse/ADF-3901)
for more information.
- `<adf-form>`: The `onError` event (emitted when any error occurs) was deprecated
in v2.4.0. It has now been renamed as `error`.
- `context-menu-holder` is now `adf-context-menu-holder`.
- The `file-draggable` event (emitted when one or more files are dragged and dropped
onto the draggable element) was deprecated in v2.4.0 and has now been removed.
Use `filesDropped` instead to get the same effect.
- The `DocumentListService.hasPermission` method was redundant and has now been removed.
Use `ContentService.hasAllowableOperations` instead.
- The `diagram-sequence-flow` tag has now been renamed as `adf-diagram-sequence-flow`.
The old name was deprecated in v2.3.0.
- The `diagram-alfresco-publish-task` tag has now been renamed as
`adf-diagram-publish-task`. The old name was deprecated in v2.3.0.
- `<adf-login>`: The `disableCsrf` input has been removed. Use the `disableCsrf`
property in `app.config.json` instead.
- `<adf-login>`: The `providers` input has been removed. Use the `providers`
property in `app.config.json` instead.
- `<adf-document-list>`: The `skipCount` input has been removed. You can define
the same value in pagination using the `pageSize` property.
- `<adf-document-list>`: The `enableInfiniteScrolling` input has been removed since
it is not used anymore. To choose the pagination strategy, add either the
[Infinite Pagination Component](../core/infinite-pagination.component.md) or the normal [Pagination Component](../core/pagination.component.md) and assign
your document list as the `target`.
- `<adf-document-list>`: The `folderNode` input has been removed. Use
the `currentFolderId` and `node` inputs instead.
- `SettingsService` has been removed. This was deprecated in v1.7.0.
- `FormService`: the `addFieldsToAForm` method has been removed.
- `<file-uploading-dialog>` has been renamed to `<adf-file-uploading-dialog>`.
- [PR JS-API](https://github.com/Alfresco/alfresco-ng2-components/pull/4097):
- The name package of the JS-API has been modified to use the namespace and all
**alfresco-js-api** imports need to be modified to **@alfresco/js-api**.
See the official
[JS-API documentation](https://github.com/Alfresco/alfresco-js-api)
for more details on how to use the new v3.0.0
[Legacy Endpoint porting](https://github.com/Alfresco/alfresco-js-api#legacy-endpoint-porting-ver-2xx).
- The JS-API `callApi` method signature has been modified. The `authNames`
parameter has now been removed because the type of authentication is configured
when the JS-API is constructed.
v2.6.1 and before:
```ts
callApi(
path: string,
httpMethod: string,
pathParams?: any,
queryParams?: any,
headerParams?: any,
formParams?: any,
bodyParam?: any,
authNames?: string[],
contentTypes?: string[],
accepts?: string[],
returnType?: any,
contextRoot?: string,
responseType?: string
): Promise<any>;
```
After v3.0.0:
```ts
callApi(
path: string,
httpMethod: string,
pathParams?: any,
queryParams?: any,
headerParams?: any,
formParams?: any,
bodyParam?: any,
contentTypes?: string[],
accepts?: string[],
returnType?: any,
contextRoot?: string,
responseType?: string
): Promise<any>;
```
- [PR JS-API](https://github.com/Alfresco/alfresco-ng2-components/pull/4097) - [PR ADF-4062](https://github.com/Alfresco/alfresco-ng2-components/pull/4294)
-The name package of the JS-API has been modified to use the namespace and all the **alfresco-js-api** import needs to be modified in **@alfresco/js-api**. Please give a look on the official [JS-API documentation](https://github.com/Alfresco/alfresco-js-api) for more details on how to use the new 3.0.0 version [Legacy Endpoint porting](https://github.com/Alfresco/alfresco-js-api#legacy-endpoint-porting-ver-2xx) - `adf-node-permission` has been renamed `adf-check-allowable-operation`.
- `ContentService.hasPermission` was actually checking the `allowableOperation` value
- The js-api callApi method firm has been modified. **authNames** has been removed as parameter. The kind authentication is configured at contruction time of the JS-API. and has been renamed as `ContentService.hasAllowableOperations`.
before 2.6.1: - `ContentService.hasPermissions` is a new method which actually *does* check
```js callApi(path: string, httpMethod: string, pathParams?: any, queryParams?: any, headerParams?: any, formParams?: any, bodyParam?: any, authNames?: string[], contentTypes?: string[], accepts?: string[], returnType?: any, contextRoot?: string, responseType?: string): Promise<any>; ``` the permissions.
after 3.0.0:
```js callApi(path: string, httpMethod: string, pathParams?: any, queryParams?: any, headerParams?: any, formParams?: any, bodyParam?: any, contentTypes?: string[], accepts?: string[], returnType?: any, contextRoot?: string, responseType?: string): Promise<any>; ```
- [PR ADF-4062](https://github.com/Alfresco/alfresco-ng2-components/pull/4294)
- ```html adf-node-permission ``` has been renamed ```html adf-check-allowable-operation ```
- ```js ContentService.hasPermission ``` was actually checking the allowableOperation and has been renamed in ```js ContentService.hasAllowableOperations ```
- ```js ContentService.hasPermissions ``` new method has been created nad it actually checking the permissions