Skip to content

Commit

Permalink
Merge branch 'next' into feat/cs-43669-live-preview-support-1.0-2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
abhinav-from-contentstack committed Feb 1, 2024
2 parents e42af72 + c067ee1 commit 46b0e59
Show file tree
Hide file tree
Showing 9 changed files with 8,457 additions and 251 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/sca-scan.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@ jobs:
env:
SNYK_TOKEN: ${{ secrets.SNYK_TOKEN }}
with:
args: --all-projects --fail-on=all
args: --all-projects --fail-on=all
6 changes: 2 additions & 4 deletions .talismanrc
Original file line number Diff line number Diff line change
@@ -1,16 +1,14 @@
fileignoreconfig:
- filename: package-lock.json
checksum: 227057b277330f78f01b86fbcb7cc622036cd9eebd5ad3c60b19f6b58e94ed91
checksum: b9a694f69c05d3cc2ef74f5b8c4507fef8b4602232436b31d30a60656fe29ec9
- filename: test/typescript/taxonomy.test.ts
checksum: e4bdf633e147fd60d929d379f20c814eed5f68b11421d7b53ec8826e9142de37
- filename: src/core/modules/taxonomy.js
checksum: 84589be9805c1be5fd6c56021c41d18365126cf82059ad2cbef1d418c70d08e0
- filename: src/core/lib/utils.js
checksum: 6018f9f13fa32b724d09b9cdf5f78cf030a6332ca549651e1e35fe91e8c7e0e7
checksum: 8a37566d0372573b8fe4ec506a43f1074981c5218e9adbc551c87922c8914922
- filename: src/core/modules/query.js
checksum: c88b336f9a271397ffedcf8c5085941ceb0bd1cd7e25ed9ada3acd8ce4f8970c
- filename: test/typescript/stack.test.ts
checksum: bbb3c425f8e1a63d4793f69ee9eaba9559294ff53f163a28f70ae54b1792276a
- filename: test/typescript/live-preview.test.ts
checksum: 57c355f5ad4070cbc3c35a2867487bef80c71be27079496e6997e0d2baec26ab
version: ""
10 changes: 6 additions & 4 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,17 +1,19 @@
## Change log

### Version: 3.18.1
### Version: 3.18.2
#### Date: February-01-2024
##### New Features:
- live preview support both 1.0 and 2.0
### Version: 3.18.1
#### Date: January-30-2024
##### New Features:
- added fix for `ESM module cannot use module.exports` issue
### Version: 3.18.0
#### Date: January-24-2024
#### Date: January-15-2024
##### New Features:
- added taxonomy support
- X-User-Agent updated
- added region gcp_na
##### Update api and enhancement:
- live preview support for rest api support
### Version: 3.17.2
#### Date: November-15-2023
##### Bug fix:
Expand Down
2 changes: 1 addition & 1 deletion config.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ const config = {
},
live_preview: {
enable: false,
host: 'rest-preview.contentstack.com'
host: 'api.contentstack.io'
}
};

Expand Down
17 changes: 3 additions & 14 deletions index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -72,21 +72,10 @@ export interface ContentTypeCollection {
count?: number
}

export type LivePreview = {
host?: string
export interface LivePreview {
host: string
management_token: string
enable: boolean
} & (LivePreivewConfigWithManagementToken | LivePreviewConfigWithPreviewToken)

export interface LivePreivewConfigWithManagementToken {
/**
* @deprecated Please use `preview_token` instead to enable live preview.
* The `management_token` will be removed in future releases.
*/
management_token: string;
}

export interface LivePreviewConfigWithPreviewToken {
preview_token: string;
}

export interface LivePreviewQuery {
Expand Down
Loading

0 comments on commit 46b0e59

Please sign in to comment.