-
Notifications
You must be signed in to change notification settings - Fork 270
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Fix] Update Text components to accept number values #713
Conversation
This pull request is being automatically deployed with Vercel (learn more). 🔍 Inspect: https://vercel.com/sitecore-jss/edge-e2e-styleguide/G6ub1nVW7yrRkG6iwPt2rsLPfa8W |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See my comments below. Also you need to update values in styleguide.yml files, check this files:
https://github.com/Sitecore/jss/blob/bug/479677/samples/react/data/routes/styleguide/en.yml#L61
https://github.com/Sitecore/jss/blob/bug/479677/samples/nextjs/data/routes/styleguide/en.yml#L61
And add unit test for sitecore-jss-angular
…alue when value doesn't contain line breaks
…ded tests to cover empty string (should not render).
@illiakovalenko Good catch with the yml files, done. We've also added tests for angular. |
* version v16.0.0-canary.52 [skip ci] * get rid of TODO * version v16.0.0-canary.53 [skip ci] * v16.1.0-canary.0 * version v16.1.0-canary.1 [skip ci] * [JSS] Disallow file deploy for Next.js solutions (#609) * [JSS] Disallow file deploy for Next.js solutions * Use `sitecoreDistPath` property * version v16.1.0-canary.2 [skip ci] * [NextJs] Sample app configuration options for 'jss create' (#618) * Prep for 'jss create' template customizations: * Pull Rest/GraphQLDictionary/LayoutService creation out of page-props-factory to separate factories for each (REST by default). * Move the [[..path]].SSR.tsx alongside default (SSG) one under /pages * Added --fetchMode and --renderMode 'jss create' parameters to nextjs template * fixed formatting * Use "enum" for Fetch/RenderMode * Parameters renamed: "fetchMode" > "fetchWith", "renderMode" > "prerender" Co-authored-by: Adam Brauer <[email protected]> * version v16.1.0-canary.3 [skip ci] * [JSS] [Angular] Pull server bundle build improvements (#617) * remove the need for the server-wrapper * remove webpack config * Create valid bundle * Add empty line * Add empty line * Remove 'exclude' option * Change doc related to angular bundles Co-authored-by: Erik van 't Klooster <[email protected]> * [sitecore-jss] Add GraphQLLayoutService (#614) * [sitecore-jss] Add GraphQLLayoutService * Change jsdoc * add changes * Use latest schema * Optional cahining for `data` * Add ability to use custom search query * remove param * Provide ability to format only query arguments instead of modifying response data * version v16.1.0-canary.4 [skip ci] * Fixed nextSteps.push * version v16.1.0-canary.5 [skip ci] * Update dev branch with new documentation from master (627) This includes the new docs pages written since the 16.0.0 release and the deployment fixes that were done as part of the 16.0.0 release ------------------------------------------ * push lock's * revert package.json * v16.0.0 * Revert lockfileVersion on master (#610) * Revert "push lock's" This reverts commit e951cc4. # Conflicts: # packages/sitecore-jss-angular-schematics/package-lock.json # packages/sitecore-jss-angular/package-lock.json # packages/sitecore-jss-cli/package-lock.json # packages/sitecore-jss-dev-tools/package-lock.json # packages/sitecore-jss-forms/package-lock.json # packages/sitecore-jss-manifest/package-lock.json # packages/sitecore-jss-nextjs/package-lock.json # packages/sitecore-jss-proxy/package-lock.json # packages/sitecore-jss-react-forms/package-lock.json # packages/sitecore-jss-react-native/package-lock.json # packages/sitecore-jss-react/package-lock.json # packages/sitecore-jss-rendering-host/package-lock.json # packages/sitecore-jss-tracking/package-lock.json # packages/sitecore-jss-update-package/package-lock.json # packages/sitecore-jss-vue/package-lock.json # packages/sitecore-jss/package-lock.json # packages/sitecore-pipelines/package-lock.json # samples/angular/package-lock.json # samples/nextjs/package-lock.json # samples/node-headless-ssr-proxy/package-lock.json # samples/react-native/package-lock.json # samples/react/package-lock.json # samples/sitecore-embedded-jss-app/package-lock.json # samples/sitecore-javascript-renderings/package-lock.json # samples/vue/package-lock.json * addl lock updates from lerna reset Co-authored-by: Adam Brauer <[email protected]> * [Doc] [NextJs] Node extra CA certificates configuration (#612) * Doc: Configure Sitecore CA certificates for Node.js * Cross-link / consolidate on walkthrough-dotnetnew * Cross-links from headless mode docs * Fix minor lang issues * Format UI labels, add emphasis Co-authored-by: Adam Brauer <[email protected]> Co-authored-by: Anca Emcken <[email protected]> * [Doc] [NextJS] Error routes (#611) * [Doc] [NextJS] Error routes * Update en.md * Add improvements * Fix punctuation Co-authored-by: Anastasiya Flynn <[email protected]> Co-authored-by: Anca Emcken <[email protected]> * [Docs] Troubleshooting page (#613) * [Docs] Troubleshooting page * Add lang review * PR review improvements * Doc wording consistency Co-authored-by: Adam Brauer <[email protected]> * Apply house style rule (where -> what) We always tell WHERE the user is to do things, then WHAT to do. * Address language and style issues * Edit 'troubleshooting' page Improve clarity per PR comments, add a note for checking sitecore config values, remove blurry image. * Review language & style * Fix hard to read sentence * Encode ..., escape [] Co-authored-by: Anca Emcken <[email protected]> Co-authored-by: Adam Brauer <[email protected]> * [Docs] [NextJs] Experience Editor Integration Architecture and APIs (#616) * EE integration architecture and APIs doc Co-authored-by: Adam Brauer <[email protected]> Co-authored-by: Anca Emcken <[email protected]> * Fix typo (#621) * [Docs][NextJS] Extract Next.js telemetry info into new page (#615) * Extract Next.js telemetry info into new page * Update navigation * [Doc] [NextJS] Error routes (#611) * [Doc] [NextJS] Error routes * Update en.md * Add improvements * Fix punctuation Co-authored-by: Anastasiya Flynn <[email protected]> Co-authored-by: Anca Emcken <[email protected]> * Fix route name Co-authored-by: Illia Kovalenko <[email protected]> Co-authored-by: Anastasiya Flynn <[email protected]> Co-authored-by: Adam Brauer <[email protected]> * typo iterfaces -> interfaces (#600) Co-authored-by: Adam Brauer <[email protected]> * Fix heading in note box (#622) * Nav updates for new troubleshooting pages (#623) Co-authored-by: Adam Brauer <[email protected]> * Merge branch 'master' from heroku remote into updates-from-master # Conflicts: # lerna.json # packages/sitecore-jss-angular-schematics/package-lock.json # packages/sitecore-jss-angular-schematics/package.json # packages/sitecore-jss-angular/package-lock.json # packages/sitecore-jss-angular/package.json # packages/sitecore-jss-cli/package-lock.json # packages/sitecore-jss-cli/package.json # packages/sitecore-jss-dev-tools/package-lock.json # packages/sitecore-jss-dev-tools/package.json # packages/sitecore-jss-forms/package-lock.json # packages/sitecore-jss-forms/package.json # packages/sitecore-jss-manifest/package-lock.json # packages/sitecore-jss-manifest/package.json # packages/sitecore-jss-nextjs/package-lock.json # packages/sitecore-jss-nextjs/package.json # packages/sitecore-jss-proxy/package-lock.json # packages/sitecore-jss-proxy/package.json # packages/sitecore-jss-react-forms/package-lock.json # packages/sitecore-jss-react-forms/package.json # packages/sitecore-jss-react-native/package-lock.json # packages/sitecore-jss-react-native/package.json # packages/sitecore-jss-react/package-lock.json # packages/sitecore-jss-react/package.json # packages/sitecore-jss-rendering-host/package-lock.json # packages/sitecore-jss-rendering-host/package.json # packages/sitecore-jss-tracking/package-lock.json # packages/sitecore-jss-tracking/package.json # packages/sitecore-jss-update-package/package-lock.json # packages/sitecore-jss-update-package/package.json # packages/sitecore-jss-vue/package-lock.json # packages/sitecore-jss-vue/package.json # packages/sitecore-jss/package-lock.json # packages/sitecore-jss/package.json # packages/sitecore-pipelines/package-lock.json # packages/sitecore-pipelines/package.json # samples/angular/package-lock.json # samples/angular/package.json # samples/nextjs/package-lock.json # samples/nextjs/package.json # samples/node-headless-ssr-proxy/package-lock.json # samples/node-headless-ssr-proxy/package.json # samples/react-native/package-lock.json # samples/react-native/package.json # samples/react/package-lock.json # samples/react/package.json # samples/sitecore-embedded-jss-app/package-lock.json # samples/sitecore-embedded-jss-app/package.json # samples/sitecore-javascript-renderings/package-lock.json # samples/sitecore-javascript-renderings/package.json # samples/vue/package-lock.json # samples/vue/package.json * origin and heroku remotes has difference app roots, so these changes are supposed to be on docs/package.json Co-authored-by: illiakovalenko <[email protected]> Co-authored-by: illiakovalenko <[email protected]> Co-authored-by: Adam Brauer <[email protected]> Co-authored-by: Adam Brauer <[email protected]> Co-authored-by: Anca Emcken <[email protected]> Co-authored-by: Illia Kovalenko <[email protected]> Co-authored-by: Calvin Williams <[email protected]> * version v16.1.0-canary.6 [skip ci] * [JSS] [React Native] Update packages, fix issues (#624) * Add changes * add changes * Fix issues * update packages * Push package-lock * Add release note * update react-native svg in sitecore-jss-react-native * Updated env setup doc link / tab name * Fix component params example for connected mode - all params will come in as string from layout service * Fix image sample 'src' prop type for disconnected - this will be number in disconnected, string in connected * Fixed tunnel for use of secure (https) Sitecore endpoints. Updated to latest ngrok. * Release note updates * Added height / width to plain image example (these are required for network images i.e. connected mode). Removed srcSet / adaptive image example since it's not supported. Co-authored-by: Adam Brauer <[email protected]> * version v16.1.0-canary.7 [skip ci] * NPM package security audit & updates (#633) * Dependency audit - root: Removed metro, updated ini * Dependency audit - package updates (all semver-compatible, only low remaining) * Dependency audit - nextjs sample * Dependency audit - react, sitecore-embedded-jss-app, sitecore-javascript-renderings, vue samples * Dependency audit - e2e * lock file updates Co-authored-by: Adam Brauer <[email protected]> * version v16.1.0-canary.8 [skip ci] * [Docs][NextJs] Account for new `fetchWith` and `prerender` configuration options for 'jss create' (#620) * Progress on doc updates for SSG/SSR & REST/GraphQL app modes * parameter rename * Another batch of updates * Added 'Switching between REST and GraphQL' doc, minor cleanup * Update "Tracking & Analytics Overview and Architecture" docs Explicitly state that SSR is required for personalization, to avoid confusion * Add jss create to CLI reference docs * Add reference to CLI doc * Added clarification to analytics support (SSR with Sitecore Layout Service REST API only) to "How is Next.js Different" doc * Provide more detailed example for `jss create` with optional params * Concentrate REST & SSR info in a pre-requisites section & clean up * Re-work intro, adjust heading levels * Drop parens * Change wording * Add CLI reference link, add headings for the switch sections * Change case for consistency * Add note about visitor consent for tracking * Change heading Co-authored-by: Adam Brauer <[email protected]> Co-authored-by: Anastasiya Flynn <[email protected]> Co-authored-by: Anca Emcken <[email protected]> * 459490 GraphQL-based dictionary service (#631) Create new GraphQL-based dictionary service implementation in sitecore-jss GraphQLDictionaryService (implements DictionaryService interface) using the layout query to get site root item using the search query to get all dictionary phrases in the site (by template) accounting for search query pagination RestDictionaryService and RestDictionaryService inherit common functionality from new abstract class DictionaryService This branch also has refactoring to organize our services classes better (not that we have more of them) and to make files in sitecore-jss follow consistent naming conventions. Renamed classes: LayoutService -> RestLayoutService LayoutServiceInstanceConfig -> RestLayoutServiceConfig DictionaryService -> RestDictionaryService DictionaryServiceConfig -> RestDictionaryServiceConfig DictionaryServiceData -> RestDictionaryServiceData (and removed from export since it's not used in the sample apps) HtmlJsonFetcher -> HtmlDataFetcher (renamed because the return type is arbitrary and not guaranteed to be JSON) New classes: GraphQLLayoutService, GraphQLLayoutServiceConfig ---------------- * Create utils/routingUtils.ts Move query string formatting out of the dataApi file, and into a general routing util fil since it can be used by other APIs too. * Combine util functions into a common namespace Now all util functions are available from the 'util' module exported from sitecore-jss * extract getUrl * Standardize file naming in sitecore-jss * Standardize file naming in sitecore-jss * Everything in the 'data-fetcher' module is coupled to Axios, so lets rename it to 'axios-fetcher' and use 'data-fetcher' for the underlying generic interface * Everything in the 'data-fetcher' module is coupled to Axios, so lets rename it to 'axios-fetcher' and use 'data-fetcher' for the underlying generic interface * Rename type HttpJsonFetcher -> HttpDataFetcher This is a generic type, so there is no guarantee that the result is JSON. The result can be any type. * Rename the sample app's data-fetcher to data-fetcher-factory to better describe what it's doing and to make it consistent with our other files * whitespace and todo for later * Rebase with dev and move some of the refactoring to a separate branch * TODOs for later * This is left-over from the refactoring that moved to another branch * GraphQLDictionaryService implementation * Add pagination and error handling to GraphQL Dictionary service; split the 2 dictionary services into separate files; create base class for dictionary services to share code * Update graphql-request-client - remove private passthrough function that isn't needed; add error handling * Add caching to graphql dictionary service * linting * Give name/date context to TODOs So we know who to bug 😸 * Update references to renamed exports * Use lower case for GUIDs * Show more data in graphql client errors * Ignore *.eslintcache * GraphQL dictionary service now fetches the root item ID, so it does not have to be provided explicitly * lint * unit tests * Undo accidental commit * Use Object.freeze on dictionary service constants * Rename DictionaryService methods - getCacheValue and setCacheValue * Add doc comments to GraphQLDictionaryServiceConfig * GraphQLDictionaryService - extract default pageSize into 'defaults' object * Rename graphql.dictionary-service to graphql-dictionary-service. Rename rest.dictionary-service to rest-dictionary-service. * Rethrow error from promise chain in graphql-request-client * Improve comments in data-fetcher.ts * Comments * lint * fetchDictionaryData - do not use make return value depend on cache * Revent renaming of src\lib\data-fetcher.ts * Update comments and variable name * jssAppTemplateId should be a required variable in the getRoot query * capitalize DEFAULTS object name * Rename appName -> siteName * version v16.1.0-canary.9 [skip ci] * [JSS] [Angular] Update to Angular 11 (#635) * changes * update to 11.2.6 * Fix angular schematics * Update apollo client * Upgrade typescript-eslint * upgrade angular-eslint * update packages * upgrade test packages * Update sitecore-jss-angular packages * Upgrade angular-devkit * FIx error: JssModule can't read property 'emod' of undefined * Add chalk, fix deprecations * Push lock files * Remove deprecated extractCss * Release notes * Fix typo * Fix ini (low severity) vulnerability * Edit release-notes Co-authored-by: Adam Brauer <[email protected]> * version v16.1.0-canary.10 [skip ci] * [NextJs] Sitecore Experience Edge Authentication (#636) * Added 'sc_apikey' header authentication for GraphQL layout and dictionary services * Added sc_apikey header / param to GraphQL sitemap service. Started sample app updates. * Fixed siteRootQuery error: Variable "$language" of type "String" used in position expecting type "String!" * Generate environment variables for computed config values as well * Added GRAPH_QL_ENDPOINT to .env file and Vercel deployment doc * PR feedback: use endpoint const, get rid of "calculated config" verbiage * Removed prettier comment * PR feedback: removed "Edge" usage for XM references Co-authored-by: Adam Brauer <[email protected]> * version v16.1.0-canary.11 [skip ci] * [node-headless-ssr-experience-edge] Add new starter template for SSR from Experience Edge (#628) * Push first changes * commit * push files * Exclude sample from e2e * push package-lock * update readme.md * Update readme * update config * update * refactoring * Add changes * Remove rewrite_exclude_urls * Added API_KEY * add todo for testing of graphql queries * Change validation message * Change canary version * Push package-lock * Add changes after review * Update pre-requisite * Update canary build * Add changes related to sc_apikey header * Update config apiKey description * Update sc_apikey header description * Update canary version * Push lock files * Fix UT * version v16.1.0-canary.12 [skip ci] * [sitecore-jss] [DictionaryService] fix memory cache (#639) * version v16.1.0-canary.13 [skip ci] * Next.js create param info for dotnet new template * [sitecore-jss] [nextjs] Use consistent not found handling for layout requests (#640) * Align not found return type * Fix ts types * add UT * take response data when 404 * cover by UT * covery by UT * Add updates * Make some methods private, cover error case by UT * version v16.1.0-canary.14 [skip ci] * [Next.js] Remove Apollo dependency for GraphQL (#642) * Use typed-document plugin instead of apollo. Remove apollo-client * Add typed-document-node package, required * Push package.lock * Change jsdoc * version v16.1.0-canary.15 [skip ci] * [NextJS] Handle change to route type to allow nulls. (#643) Build context object in [[...path]] instead of in Layout, since the former is aware of whether route is null or not * version v16.1.0-canary.16 [skip ci] * [JSS] [NextJs] Sitemap query limits to 10 by default (#644) * whitespace * rebase onto dev * Add pagination to sitemap service * improve comments * Add more error handling to graphql-sitemape-service * unit tests & lint * Release notes * Improve comments and type checking * Fix merge issues * Change visibility of GraphQLSitemapService.fetch to protected * version v16.1.0-canary.17 [skip ci] * [JSS] [NextJs] Debug Logging (#645) * Low-level http request/response debug logging ("sitecore-jss:http" namespace) for both GraphQL (`graphql-request-client.ts`) and REST/fetch (`axios-fetcher`). Feature-level logging for dictionary and layout ("sitecore-jss:dictionary" and "sitecore-jss:layout" namespaces). * Debug log tests for http logging * Use object formatting, Axios 'toJSON' if available for errors * Sitemap and experience editor feature-level logging * Add rootItemId.toLowerCase() back to GraphQL sitemap query * Added documentation * Added to release notes * PR feedback: SDKs > npm packages, added note about server-side only logs * PR feedback: Centralized debug 'debuggers' in sitecore-jss * Allow debugger injection into low-level http wrappers (axios-fetcher and graphql-request-client) so that these request/response logs can appear under feature-level namespaces. * Updated docs * Fix lint error * version v16.1.0-canary.18 [skip ci] * Renamed debug logging namespace "sitecore-jss:experience-editor" > "sitecore-jss:editing" * version v16.1.0-canary.19 [skip ci] * [Docs][469075] Add notes on compatibility & CLI example for older JSS releases (#634) * Update params, include example for specific release version * Add version compatibility info Include links to the compatibility table and to the CLI reference (updated with an example for creating an app using a previous version of JSS). * Fix typo * Add version compatibility note and link to table * Add compatibility note * Add note on Sitecore and JSS versions * Change versioning wording * [NextJs] GraphQL schema updates and fragment data generation removal (#648) * Removed GraphQLFragmentTypes.json and corresponding script to generate. This is no longer needed with our removal of Apollo in the sample app. Also, added apikey to the introspection fetch and switched to use our GraphQLRequestClient as opposed to cross-fetch. * Updates for item children GraphQL edge schema change (now uses item search results pattern vs an array of items). * version v16.1.0-canary.20 [skip ci] * Added DEBUG_MULTILINE to allow switching from %o (pretty-print single line) to %O (pretty-print multiple line) formatting (#649) * version v16.1.0-canary.21 [skip ci] * NPM package security update: 'url-parse' and 'y18n' (#651) * 'url-parse' dependency removal / upgrade to address vulnerability with v1.4.7 (https://nvd.nist.gov/vuln/detail/CVE-2021-27515) * Address y18n vulnerability (high): https://www.npmjs.com/advisories/1654 * lock file updates (npm run reset) * Remove url-parse from sitecore-jss-angular, remove @types from sitecore-jss-forms * Push lock files Co-authored-by: illiakovalenko <[email protected]> * version v16.1.0-canary.22 [skip ci] * [Doc] Remove `remove language from package.json` step in `Walkthrough: Using next export` (#658) * Update PULL_REQUEST_TEMPLATE.MD Removed checklist * Update PULL_REQUEST_TEMPLATE.MD Combined description and motivation sections. Reworded Testing section title * version v16.1.0-canary.23 [skip ci] * CONTRIBUTING refresh: node/npm versions, 'dev' branch now default (#673) * version v16.1.0-canary.24 [skip ci] * [sitecore-jss-nextjs] Links inside RichText control cause page to be loaded twice (#659) * Fix internal links initialization * Add doc * version v16.1.0-canary.25 [skip ci] * [Angular] Extend description for Lazy Loading component (#674) * version v16.1.0-canary.26 [skip ci] * Feature/469713 (#656) * Refactoring - avoid duplicating getQueryString and other URL resolving logic; add unit tests for this function * Reorganize modules related to layout service - move them into their own folder and separate rest/graphql, similar to what we did with dictionary modules * remove 'data-api' file to improve the dependency hierarchy * Use proper querystring types from @types/node/querystring * break up util functions - isolate EE utils in 'experience-editor' file; break out logic for resolving app root into its own util for reuse in sitemap * Move test data for unit tests into a separate json file * Update properties in sitecore-jss/package.json * Enable syntax highlighting on graphql string via prettier * set noUnusedLocals to true in sitecore-jss-nextjs Co-authored-by: Adam Brauer <[email protected]> * version v16.1.0-canary.27 [skip ci] * Bug/475365 (#679) * Fit error about missing http module - apparently importing and then exporting a lib in this manner is not ok * Fix circular dependency in src/utils/experience-editor * Add index/ts file under /i18n for easier imports * Add a table comparing API of sitecore-jss 16.0 vs 18.0 to migration guide and fix a couple missing exports * version v16.1.0-canary.28 [skip ci] * [node-headless-ssr-proxy + Angular sample] Error in console when refresh /graphql page (#680) * [node-headless-ssr-proxy + Angular sample] Error in console when refresh /graphql page * Update release notes * version v16.1.0-canary.29 [skip ci] * Feature/475116 (#682) * Update SitePageQuery (used by sitemap) to use a variable for "_hasLayout" clause * Add "contains operator" to our graphql search() queries and start docs for edge-specific graphql requirements * Add query example to docs * version v16.1.0-canary.30 [skip ci] * [sitecore-jss-forms] Fix for multi-valued fields with pre-filled form data (#677) * Fix issue where pre-filled (default) form data isn't removed for multi-valued fields when user de-selects values. * Added release note * version v16.1.0-canary.31 [skip ci] * Fix lint issues * Push package lock * Edit line endings before write to file, force to use CRLF * Extend description * Extend description * Edit line endings for Vue sample * version v16.1.0-canary.32 [skip ci] * [sitecore-jss] [mediaApi] `updateImageUrl` fix for invalid hash errors on Sitecore (#681) * media-api updateImageUrl update - *only* switch to JSS media handler prefix if image params are sent. Otherwise, the original media URL should be returned. Fixes hash errors from appearing in Sitecore logs ("ERROR MediaRequestProtection: An invalid/missing hash value was encountered.") * added release note * Don't modify 'params' parameter! * Also check 'params' object keys b/c of cases where an empty object is passed in by the frameworks usage (and in fact the srcset logic appears to do that) * version v16.1.0-canary.33 [skip ci] * Dependency upgrades - High severity vulnerabilities (#685) * vulnerability updates: ssri (https://nvd.nist.gov/vuln/detail/CVE-2021-27290), ini (https://nvd.nist.gov/vuln/detail/CVE-2020-7788), y18n (https://nvd.nist.gov/vuln/detail/CVE-2020-7774), lodash (https://nvd.nist.gov/vuln/detail/CVE-2021-23337) * Semver-compatible vulnerability updates for /docs (just keep on life support for now) * version v16.1.0-canary.34 [skip ci] * Bug/472144 (#683) * Add default language for node-headless-ssr-experience-edge * Add todo to fix similar issue in headless-ssr-proxy * Update README.md * version v16.1.0-canary.35 [skip ci] * Bump lerna version to match ci / lock version (3.22.x) for local development. Misc lock files updated (after reset). * version v16.1.0-canary.36 [skip ci] * [node-headless-ssr-experience-edge] Update readme (#688) * version v16.1.0-canary.37 [skip ci] * Add dataApi, mediaApi back to sitecore-jss-nextjs package export * version v16.1.0-canary.38 [skip ci] * [NextJs] Switch sample app source to GraphQL by default (#689) Switch the source code default fetch for layout and dictionary data to GraphQL. REST will remain the default for jss create (--fetchWith). Updates to docs as needed. * version v16.1.0-canary.39 [skip ci] * [JSS] Address high severity vulnerabilities (#691) * Update packages * Uppdate other packages * Revert sitecore-jss-nextjs `next` package version * version v16.1.0-canary.40 [skip ci] * Feature/467450 - Edge GraphQL query & services updates (#692) Functional changes: * Update introspection, and connected/disconnected GraphQL components in Next sample to account for latest Edge scheme. The change is that `language` is required in all queries. This fixes the broken build. Non-functional devEx improvements: * Add CacheClient and GraphQLClient interfaces to allow implementations to override which 3rd party libs are used by services. * Pull shared functionality related to using `search` query (ie handling pagination) into new SearchQueryService; update GraphQLDictionaryService and SitemapService to use this service. * Make it easier to customize our services by changing access level of methods from private to protected Misc changes: * [sitecore-jss] Move app root query functionality from /utils to /graphql * Fix typo in docs * version v16.1.0-canary.41 [skip ci] * Add language fallback settings to nextjs sample config (#695) * version v16.1.0-canary.42 [skip ci] * [NextJs] Added IncludeServerUrlInMediaUrls "default" configuration to Next.js sample app (necessary for Sitecore GraphQL Edge) (#696) * version v16.1.0-canary.43 [skip ci] * [sitecore-jss] [graphql-dictionary-service] use "Key" and "Phrase" capitalized (#697) * version v16.1.0-canary.44 [skip ci] * Fix typo * GraphQLSitemapService - allow overriding of query and search service (#705) * version v16.1.0-canary.45 [skip ci] * [Docs][474350] Document the new starter template for SSR (#694) * Document node-headless-ssr-experience-edge * Add nav item for SSR with Edge * Emphasize the experimental nature of the template * Specify that non-next.js apps use legacy/non-Edge schema. * Fix typo, improve clarity * Add ssr-edge sample to list of experimental templates * Review language * Add third-party note on Node.js as per PBI 435247 Co-authored-by: Anca Emcken <[email protected]> * Use correct 'layout' debug namespace for graphql-layout-service. * version v16.1.0-canary.46 [skip ci] * Fix merge conflict - this comment was in the wrong place * version v16.1.0-canary.47 [skip ci] * [sitecore-jss-react] [Text] Render value instead of array of single value when value doesn't contain line breaks (#714) * version v16.1.0-canary.48 [skip ci] * [sitecore-jss] Rest Layout Service - Allow override of "named" JSS configuration (#716) * [RestLayoutService] Allow override of "named" JSS configuration * Add UT Co-authored-by: illiakovalenko <[email protected]> * version v16.1.0-canary.49 [skip ci] * Allow to publish canary for release branches * version v16.1.0-canary.50 [skip ci] * [Fix] Update Text components to accept number values (#713) * Update Text components to accept number values * [sitecore-jss-react] [Text] Render value instead of array of single value when value doesn't contain line breaks * PR feedback - handle zero number value, added tests to cover. Also added tests to cover empty string (should not render). * Update react/nextjs number fields in styleguide route manifest Co-authored-by: illiakovalenko <[email protected]> * version v16.1.0-canary.51 [skip ci] * Include release/* branches to be triggered * version v16.1.0-canary.52 [skip ci] * Trigger azure pipeline on the branch which targets release branch * version v16.1.0-canary.53 [skip ci] * Apply workaround, b/c SourceBranchName doesn't contain `release` prefix, it takes last part * Use variable * Apply fix for branchName * version v16.1.0-canary.54 [skip ci] * v18.0.0 * version v18.0.1-canary.0 [skip ci] * v18.0.0-canary.0 * version v18.0.0-canary.1 [skip ci] * [Doc] [NextJS] GraphQL + Disconnected mode compatibility (#717) * [Doc] [NextJS] GraphQL + Disconnected mode compatibility * Add route * Review language and style * Remove duplicate export Co-authored-by: Anca Emcken <[email protected]> * [Docs] Align with styleguide, fix incomplete sentence (#709) * Fix incomplete sentence * Review and update according to docs styleguide * Change case for headings Our doc styleguide requires all heading use sentence case (instead of title case). Co-authored-by: Anca Emcken <[email protected]> * Merge pull request #708 from Sitecore/docs/435247 [Docs] Explicitly mention that NodeJS is a third-party technology. * Merge pull request #710 from Sitecore/docs/445595 [Docs] Change starter->sample and associated changes + small lang & style fixes * Merge pull request #719 from Sitecore/docs/445596 [445596][Docs] Replace jss.sitecore.net with jss.sitecore.com * [Docs][Next.js] Add video walkthrough (#729) * Add video walkthrough * Update iframe src with correct embed url Co-authored-by: Anca Emcken <[email protected]> * [Docs] Update README with samples entry for Next.js and highlight features (#632) * Update with samples entry for Next.js and highlight features * Update product name * Drop mention of create-next-app * Fix small grammar issues * Update README.md Co-authored-by: Anca Emcken <[email protected]> * version v18.0.0-canary.2 [skip ci] * Update Next.js sample config - layoutServiceConfiguration="default" (#722) * Update Next.js sample config - layoutServiceConfiguration="default" * Update samples/nextjs/sitecore/config/JssNextWeb.config Co-authored-by: Adam Brauer <[email protected]> Co-authored-by: Adam Brauer <[email protected]> * version v18.0.0-canary.3 [skip ci] * [All frameworks] Execute correct detection of disconnected or connected mode (#732) * version v18.0.0-canary.4 [skip ci] * Revert "[All frameworks] Execute correct detection of disconnected or connected mode (#732)" This reverts commit 23bb5ec. * version v18.0.0-canary.5 [skip ci] * [Vue] Correct detection of disconnected mode * Add walkthrough for customizing static paths (#739) Co-authored-by: Anca Emcken <[email protected]> * [Docs] Add Edge-related material (#740) * Move video demonstration for better fit * Add link to Edge docs * Add Edge alternative to publish:end hook config * Add link to API provisioning docs for Edge * Add Sitecore XM detail to publish:end webhook Co-authored-by: Anca Emcken <[email protected]> * [Docs][Next.js]Fix step for deploying Next.js items to Sitecore [479849] (#741) * Fix step for deploying Next.js items to Sitecore * Clarify how to deploy a Next.js app to Sitecore * Push hash to history if present, account for target other than link * Handle hash when routing * Add flags docs/data/routes/docs/nextjs/getting-started-nextjs/walkthrough-jsscreate/en.md Co-authored-by: Adam Brauer <[email protected]> Co-authored-by: Anca Emcken <[email protected]> Co-authored-by: Adam Brauer <[email protected]> * [Docs] Update services (#751) * Separate content and move getStaticPaths Moves getStaticPaths documentation under "Page Routing". Redirects from old to new location. Fixes cross-references. Removes GraphQLSitemapService which should go in its own doc. * Add nav and page for GraphQLSitemapService * Add EXPORT_MODE variable to steps * Use ManifestInstance * Update deprecated signature * Update doc title * Link to first mention * [483268] Document graphQL query error for Next.js + SXA * Update GraphQLSitemapService documentation * Update navigation item * Add Services & APIs overview for fundamentals * Split back- and front-end layout service, update content Splits the Layout Service section into the front- and back-end parts for easier management of changes. Updates nav. Adds redirects as needed. * Fix typos * Add link to Next.js app lib as example of service factories * Clarify in the heading this is the REST layout service * Revert move of getStaticPaths topic * Make example framework agnostic * Remove duplicate heading * Fix typo * Remove mystery variable * Re-word factory description * Clarify JSS clients interact with Sitecore Headless services These types of distinctions become increasingly important as we separate server components from JSS services * Reorganize Layout overview * Add redirect to overview for Layout service Since server components Layout service and JSS one were mixed in a single doc, we don't know which one old links out in the world were meant to reach. By pointing at the overview, devs can then pick the one they are interested in. * Refactor Dictionary service docs Split Sitecore from JSS Add redirects Update nav * Update title * Fix indentation * Specify other services/apis * Fix redirect for layout service landing * Update layout service links * Remove dataApi reference * Expand description and provide GraphQL examples for Dictionary service * Clean up Headless Dictionary Service description * Expand description and provide GraphQL example for Layout service * Update links to dictionary service documentation * Enrich dictionary overview with info about GQL and links * Incorporate doc update from PR#744 * Remove duplicate menu item * Update docs/data/routes/docs/fundamentals/services/dictionary/overview/en.md Adds missing comma Co-authored-by: Anastasiya Flynn <[email protected]> * Move Services higher in the navigation * Change tone * Improve clarity of data fetching options * Change endpoint / product order to match bullet points * Specify the package that provides the dictionary API * Elaborate JSS Dictionary API description * Add note on sample app * Get personal * Remove obscure references to back-end concepts * Add returned data example * Change "route data" to "layout data" + small language changes * Link to query definition in branch src file * Re-arrange some content * Specify name for Edge Preview endpoint and add original gql endpoint * Add missing empty line between heading and quote * Clarify that the tracking parameter is only intended for Sitecore XP * [487542] Clarify required version of Sitecore and Headless Service for Next * [486092] Update troubleshooting: Next.js app does not render on Vercel Co-authored-by: Anca Emcken <[email protected]> Co-authored-by: Anastasiya Flynn <[email protected]> * [Docs] Generate ref docs for jss and nextjs sdks (#766) * Generate ref docs for jss and nextjs sdks * Regenerate docs with updated readmes * Update readmes and location of ref-docs * Generate ref-docs without duplicating package readme Co-authored-by: Anca Emcken <[email protected]> * version v18.0.0-canary.6 [skip ci] * Add ref docs links (#767) Co-authored-by: Anca Emcken <[email protected]> * Fix broken links to main docs (#770) Co-authored-by: Anca Emcken <[email protected]> * Add example and config for Next.js + small fixes (#769) Co-authored-by: Anca Emcken <[email protected]> * 18.0.0 Release Notes (#779) * Update release notes for v18. Create CHANGELOG file. * Add link to Sitecore Experience Edge schema docs * Link to JSS Layout / Dictionary APIs * Add link to sitecore-jss and sitecore-jss-nextjs ref docs * Fix Edge heading and add link to docs * Add section on docs and update links * Drop "API" * Wrap param names in backticks * Add link to CLI docs for create * Improve links to Edge docs sections The Edge docs were published today so we now have access to section IDs * Update links to Sitecore docs Co-authored-by: Anca Emcken <[email protected]> * version v18.0.0-canary.7 [skip ci] * Update "Found a problem" link in docs to use release/18.0.0 branch instead of master (#780) * Typo Co-authored-by: Automated Build <[email protected]> Co-authored-by: Nick Wesselman <[email protected]> Co-authored-by: Adam Brauer <[email protected]> Co-authored-by: Illia Kovalenko <[email protected]> Co-authored-by: Adam Brauer <[email protected]> Co-authored-by: Erik van 't Klooster <[email protected]> Co-authored-by: illiakovalenko <[email protected]> Co-authored-by: illiakovalenko <[email protected]> Co-authored-by: Anca Emcken <[email protected]> Co-authored-by: Calvin Williams <[email protected]> Co-authored-by: Nick Wesselman <[email protected]> Co-authored-by: Coby Sher <[email protected]> Co-authored-by: Anca Emcken <[email protected]>
* version v16.1.0-canary.15 [skip ci] * [NextJS] Handle change to route type to allow nulls. (#643) Build context object in [[...path]] instead of in Layout, since the former is aware of whether route is null or not * version v16.1.0-canary.16 [skip ci] * [JSS] [NextJs] Sitemap query limits to 10 by default (#644) * whitespace * rebase onto dev * Add pagination to sitemap service * improve comments * Add more error handling to graphql-sitemape-service * unit tests & lint * Release notes * Improve comments and type checking * Fix merge issues * Change visibility of GraphQLSitemapService.fetch to protected * version v16.1.0-canary.17 [skip ci] * [JSS] [NextJs] Debug Logging (#645) * Low-level http request/response debug logging ("sitecore-jss:http" namespace) for both GraphQL (`graphql-request-client.ts`) and REST/fetch (`axios-fetcher`). Feature-level logging for dictionary and layout ("sitecore-jss:dictionary" and "sitecore-jss:layout" namespaces). * Debug log tests for http logging * Use object formatting, Axios 'toJSON' if available for errors * Sitemap and experience editor feature-level logging * Add rootItemId.toLowerCase() back to GraphQL sitemap query * Added documentation * Added to release notes * PR feedback: SDKs > npm packages, added note about server-side only logs * PR feedback: Centralized debug 'debuggers' in sitecore-jss * Allow debugger injection into low-level http wrappers (axios-fetcher and graphql-request-client) so that these request/response logs can appear under feature-level namespaces. * Updated docs * Fix lint error * version v16.1.0-canary.18 [skip ci] * Renamed debug logging namespace "sitecore-jss:experience-editor" > "sitecore-jss:editing" * version v16.1.0-canary.19 [skip ci] * [Docs][469075] Add notes on compatibility & CLI example for older JSS releases (#634) * Update params, include example for specific release version * Add version compatibility info Include links to the compatibility table and to the CLI reference (updated with an example for creating an app using a previous version of JSS). * Fix typo * Add version compatibility note and link to table * Add compatibility note * Add note on Sitecore and JSS versions * Change versioning wording * [NextJs] GraphQL schema updates and fragment data generation removal (#648) * Removed GraphQLFragmentTypes.json and corresponding script to generate. This is no longer needed with our removal of Apollo in the sample app. Also, added apikey to the introspection fetch and switched to use our GraphQLRequestClient as opposed to cross-fetch. * Updates for item children GraphQL edge schema change (now uses item search results pattern vs an array of items). * version v16.1.0-canary.20 [skip ci] * Added DEBUG_MULTILINE to allow switching from %o (pretty-print single line) to %O (pretty-print multiple line) formatting (#649) * version v16.1.0-canary.21 [skip ci] * NPM package security update: 'url-parse' and 'y18n' (#651) * 'url-parse' dependency removal / upgrade to address vulnerability with v1.4.7 (https://nvd.nist.gov/vuln/detail/CVE-2021-27515) * Address y18n vulnerability (high): https://www.npmjs.com/advisories/1654 * lock file updates (npm run reset) * Remove url-parse from sitecore-jss-angular, remove @types from sitecore-jss-forms * Push lock files Co-authored-by: illiakovalenko <[email protected]> * version v16.1.0-canary.22 [skip ci] * [Doc] Remove `remove language from package.json` step in `Walkthrough: Using next export` (#658) * Update PULL_REQUEST_TEMPLATE.MD Removed checklist * Update PULL_REQUEST_TEMPLATE.MD Combined description and motivation sections. Reworded Testing section title * version v16.1.0-canary.23 [skip ci] * CONTRIBUTING refresh: node/npm versions, 'dev' branch now default (#673) * version v16.1.0-canary.24 [skip ci] * [sitecore-jss-nextjs] Links inside RichText control cause page to be loaded twice (#659) * Fix internal links initialization * Add doc * version v16.1.0-canary.25 [skip ci] * [Angular] Extend description for Lazy Loading component (#674) * version v16.1.0-canary.26 [skip ci] * Feature/469713 (#656) * Refactoring - avoid duplicating getQueryString and other URL resolving logic; add unit tests for this function * Reorganize modules related to layout service - move them into their own folder and separate rest/graphql, similar to what we did with dictionary modules * remove 'data-api' file to improve the dependency hierarchy * Use proper querystring types from @types/node/querystring * break up util functions - isolate EE utils in 'experience-editor' file; break out logic for resolving app root into its own util for reuse in sitemap * Move test data for unit tests into a separate json file * Update properties in sitecore-jss/package.json * Enable syntax highlighting on graphql string via prettier * set noUnusedLocals to true in sitecore-jss-nextjs Co-authored-by: Adam Brauer <[email protected]> * version v16.1.0-canary.27 [skip ci] * Bug/475365 (#679) * Fit error about missing http module - apparently importing and then exporting a lib in this manner is not ok * Fix circular dependency in src/utils/experience-editor * Add index/ts file under /i18n for easier imports * Add a table comparing API of sitecore-jss 16.0 vs 18.0 to migration guide and fix a couple missing exports * version v16.1.0-canary.28 [skip ci] * [node-headless-ssr-proxy + Angular sample] Error in console when refresh /graphql page (#680) * [node-headless-ssr-proxy + Angular sample] Error in console when refresh /graphql page * Update release notes * version v16.1.0-canary.29 [skip ci] * Feature/475116 (#682) * Update SitePageQuery (used by sitemap) to use a variable for "_hasLayout" clause * Add "contains operator" to our graphql search() queries and start docs for edge-specific graphql requirements * Add query example to docs * version v16.1.0-canary.30 [skip ci] * [sitecore-jss-forms] Fix for multi-valued fields with pre-filled form data (#677) * Fix issue where pre-filled (default) form data isn't removed for multi-valued fields when user de-selects values. * Added release note * version v16.1.0-canary.31 [skip ci] * Fix lint issues * Push package lock * Edit line endings before write to file, force to use CRLF * Extend description * Extend description * Edit line endings for Vue sample * version v16.1.0-canary.32 [skip ci] * [sitecore-jss] [mediaApi] `updateImageUrl` fix for invalid hash errors on Sitecore (#681) * media-api updateImageUrl update - *only* switch to JSS media handler prefix if image params are sent. Otherwise, the original media URL should be returned. Fixes hash errors from appearing in Sitecore logs ("ERROR MediaRequestProtection: An invalid/missing hash value was encountered.") * added release note * Don't modify 'params' parameter! * Also check 'params' object keys b/c of cases where an empty object is passed in by the frameworks usage (and in fact the srcset logic appears to do that) * version v16.1.0-canary.33 [skip ci] * Dependency upgrades - High severity vulnerabilities (#685) * vulnerability updates: ssri (https://nvd.nist.gov/vuln/detail/CVE-2021-27290), ini (https://nvd.nist.gov/vuln/detail/CVE-2020-7788), y18n (https://nvd.nist.gov/vuln/detail/CVE-2020-7774), lodash (https://nvd.nist.gov/vuln/detail/CVE-2021-23337) * Semver-compatible vulnerability updates for /docs (just keep on life support for now) * version v16.1.0-canary.34 [skip ci] * Bug/472144 (#683) * Add default language for node-headless-ssr-experience-edge * Add todo to fix similar issue in headless-ssr-proxy * Update README.md * version v16.1.0-canary.35 [skip ci] * Bump lerna version to match ci / lock version (3.22.x) for local development. Misc lock files updated (after reset). * version v16.1.0-canary.36 [skip ci] * [node-headless-ssr-experience-edge] Update readme (#688) * version v16.1.0-canary.37 [skip ci] * Add dataApi, mediaApi back to sitecore-jss-nextjs package export * version v16.1.0-canary.38 [skip ci] * [NextJs] Switch sample app source to GraphQL by default (#689) Switch the source code default fetch for layout and dictionary data to GraphQL. REST will remain the default for jss create (--fetchWith). Updates to docs as needed. * version v16.1.0-canary.39 [skip ci] * [JSS] Address high severity vulnerabilities (#691) * Update packages * Uppdate other packages * Revert sitecore-jss-nextjs `next` package version * version v16.1.0-canary.40 [skip ci] * Feature/467450 - Edge GraphQL query & services updates (#692) Functional changes: * Update introspection, and connected/disconnected GraphQL components in Next sample to account for latest Edge scheme. The change is that `language` is required in all queries. This fixes the broken build. Non-functional devEx improvements: * Add CacheClient and GraphQLClient interfaces to allow implementations to override which 3rd party libs are used by services. * Pull shared functionality related to using `search` query (ie handling pagination) into new SearchQueryService; update GraphQLDictionaryService and SitemapService to use this service. * Make it easier to customize our services by changing access level of methods from private to protected Misc changes: * [sitecore-jss] Move app root query functionality from /utils to /graphql * Fix typo in docs * version v16.1.0-canary.41 [skip ci] * Add language fallback settings to nextjs sample config (#695) * version v16.1.0-canary.42 [skip ci] * [NextJs] Added IncludeServerUrlInMediaUrls "default" configuration to Next.js sample app (necessary for Sitecore GraphQL Edge) (#696) * version v16.1.0-canary.43 [skip ci] * [sitecore-jss] [graphql-dictionary-service] use "Key" and "Phrase" capitalized (#697) * version v16.1.0-canary.44 [skip ci] * Fix typo * GraphQLSitemapService - allow overriding of query and search service (#705) * version v16.1.0-canary.45 [skip ci] * [Docs][474350] Document the new starter template for SSR (#694) * Document node-headless-ssr-experience-edge * Add nav item for SSR with Edge * Emphasize the experimental nature of the template * Specify that non-next.js apps use legacy/non-Edge schema. * Fix typo, improve clarity * Add ssr-edge sample to list of experimental templates * Review language * Add third-party note on Node.js as per PBI 435247 Co-authored-by: Anca Emcken <[email protected]> * Use correct 'layout' debug namespace for graphql-layout-service. * version v16.1.0-canary.46 [skip ci] * Explicitly mention that NodeJS is a third-party technology. * Change starter->sample and associated changes + small lang & style fixes * Fix merge conflict - this comment was in the wrong place * version v16.1.0-canary.47 [skip ci] * [sitecore-jss-react] [Text] Render value instead of array of single value when value doesn't contain line breaks (#714) * version v16.1.0-canary.48 [skip ci] * [sitecore-jss] Rest Layout Service - Allow override of "named" JSS configuration (#716) * [RestLayoutService] Allow override of "named" JSS configuration * Add UT Co-authored-by: illiakovalenko <[email protected]> * version v16.1.0-canary.49 [skip ci] * Allow to publish canary for release branches * version v16.1.0-canary.50 [skip ci] * Replace jss.sitecore.net with jss.sitecore.com * [Fix] Update Text components to accept number values (#713) * Update Text components to accept number values * [sitecore-jss-react] [Text] Render value instead of array of single value when value doesn't contain line breaks * PR feedback - handle zero number value, added tests to cover. Also added tests to cover empty string (should not render). * Update react/nextjs number fields in styleguide route manifest Co-authored-by: illiakovalenko <[email protected]> * version v16.1.0-canary.51 [skip ci] * Include release/* branches to be triggered * version v16.1.0-canary.52 [skip ci] * Trigger azure pipeline on the branch which targets release branch * version v16.1.0-canary.53 [skip ci] * Apply workaround, b/c SourceBranchName doesn't contain `release` prefix, it takes last part * Use variable * Apply fix for branchName * version v16.1.0-canary.54 [skip ci] * v18.0.0 * version v18.0.1-canary.0 [skip ci] * v18.0.0-canary.0 * version v18.0.0-canary.1 [skip ci] * v19.0.0-canary.0 * version v19.0.0-canary.1 [skip ci] * [Doc] [NextJS] GraphQL + Disconnected mode compatibility (#717) * [Doc] [NextJS] GraphQL + Disconnected mode compatibility * Add route * Review language and style * Remove duplicate export Co-authored-by: Anca Emcken <[email protected]> * [Horizon] [Next.js] Styleguide component datasource resiliency (#723) * withDatasourceCheck HOC added * Styles for default JSS error components in Next.js sample * Added withDatasourceCheck to all Next.js sample app components that require it * fixed comments * Push changes after review * Add empty line * Fix lint error Co-authored-by: illiakovalenko <[email protected]> * version v19.0.0-canary.2 [skip ci] * [NextJS] Enable monorepo in Vercel (#725) * Change next config * Update PUBLIC_URL * Remove `symlinks` option * Test * Remove test changes * Update comments * Extend description * Use getPublicUrl from base package * [Docs] Align with styleguide, fix incomplete sentence (#709) * Fix incomplete sentence * Review and update according to docs styleguide * Change case for headings Our doc styleguide requires all heading use sentence case (instead of title case). Co-authored-by: Anca Emcken <[email protected]> * Replace jss.sitecore.net with jss.sitecore.com * version v19.0.0-canary.3 [skip ci] * [Next.js] Enable dynamic component import in sample (#727) * Prove dynamic import * Change word * Change function name * version v19.0.0-canary.4 [skip ci] * [Vue] Upgrade version 2.x to 3.x (#724) * Push changes * Fix prefetch, fix vue-meta build, fix empty APOLLO_STATE * Update comments * Update docs, comments * Push package.lock * Fixes * Update types, connect types to vue proptypes * Fix UT * version v19.0.0-canary.5 [skip ci] * Don't link 'react' multiple times * version v19.0.0-canary.6 [skip ci] * Add bootstrap react, react-dom for Vercel * Fix * Remove folder * version v19.0.0-canary.7 [skip ci] * Revert changes * version v19.0.0-canary.8 [skip ci] * version v19.0.0-canary.9 [skip ci] * Fix lint issue for Vue sample * version v19.0.0-canary.10 [skip ci] * [NextJS] Use .dynamic instead of .module for lazy loading modules (#730) * Use .dynamic extension instead of .module * add files * Change function * version v19.0.0-canary.11 [skip ci] * [Docs][Next.js] Add video walkthrough (#729) * Add video walkthrough * Update iframe src with correct embed url Co-authored-by: Anca Emcken <[email protected]> * [JSS][angular] dk-DA language is not rendered in connected and disconnected mode (#734) * 🐛 fix for Danish styleguide page not loading due to strict mime type check * version v19.0.0-canary.12 [skip ci] * [All frameworks] Execute correct detection of disconnected or connected mode (#732) * version v19.0.0-canary.13 [skip ci] * [Docs] Update README with samples entry for Next.js and highlight features (#632) * Update with samples entry for Next.js and highlight features * Update product name * Drop mention of create-next-app * Fix small grammar issues * Update README.md Co-authored-by: Anca Emcken <[email protected]> * [Next.js] Prevent extraneous router.replace in Experience Editor when using SSG (#736) * version v19.0.0-canary.14 [skip ci] * [NextJS] Vercel throws 500 for NotFound and /da-DK pages (#731) * Test using modified webpack config * Add 'path' import * Update bootstrap command * Add resolutions * Push * Push nextjs package lock * Push react * Resolve symlinks for react * Remove bootstrap react * ResolveSymlinks: false * Bootstrap only react sample * Add next.config.prod.js * Remove unused dep during `jss create`, and use `next.config.base` name * Output logs in console * Apply dev changes * test log * test * test * test * Remove unused dependencies from package.json * Add logs * Change variable names to `baseConfig` * version v19.0.0-canary.15 [skip ci] * [NextJS] Linting error when there are no dynamic components in the app * version v19.0.0-canary.16 [skip ci] * Add walkthrough for customizing static paths (#739) Co-authored-by: Anca Emcken <[email protected]> * [Docs] Add Edge-related material (#740) * Move video demonstration for better fit * Add link to Edge docs * Add Edge alternative to publish:end hook config * Add link to API provisioning docs for Edge * Add Sitecore XM detail to publish:end webhook Co-authored-by: Anca Emcken <[email protected]> * [Vue] Use fragments by default with sc-placeholder (#742) * Use Vue fragment * Update doc * Update doc according the review * version v19.0.0-canary.17 [skip ci] * [Docs][Next.js]Fix step for deploying Next.js items to Sitecore [479849] (#741) * Fix step for deploying Next.js items to Sitecore * Clarify how to deploy a Next.js app to Sitecore * Push hash to history if present, account for target other than link * Handle hash when routing * Add flags docs/data/routes/docs/nextjs/getting-started-nextjs/walkthrough-jsscreate/en.md Co-authored-by: Adam Brauer <[email protected]> Co-authored-by: Anca Emcken <[email protected]> Co-authored-by: Adam Brauer <[email protected]> * [Horizon] Update editing functions for Horizon compatibility (#712) * Update sitecore-jss\nextjs\react editing functions for Horizon. Renamed functions to be editor-agnostic, but preserved existing names as pass-through functions for backward compatibility * Expose static Experience/HorizonEditor classes * Moved 'isServer()' checks to static editor class functions (proper handling of window check). Renamed additional "experience editor" > "Sitecore editor". * Use horizon reset chromes function * export getPublicUrl * [NextJS] Reset chromes when GraphqlConnectedDemo mounted (#743) * [Horizon] Empty placeholder / initial load issue (#711) * Simplified empty placeholder handling for Horizon using new reset chrome function Co-authored-by: Adam Brauer <[email protected]> Co-authored-by: illiakovalenko <[email protected]> Co-authored-by: Illia Kovalenko <[email protected]> * [sitecore-jss-react] Error rendering raw self-closing tag elements in placeholders (#745) * version v19.0.0-canary.18 [skip ci] * Remove use of deprecated dataApi (#744) * Replace dataApi by RestLayoutService * update docs * Update react-native, embedded-jss-app * Remove 'default' * Changes after review * Remove redundant interfaces * Removed remaining LayoutServiceRequestOptions refs * fix 'jss-layout.service' import in angular sample Co-authored-by: Adam Brauer <[email protected]> * version v19.0.0-canary.19 [skip ci] * [Vue] regeneratorRuntime error when opening Vue app in EE (#749) * version v19.0.0-canary.20 [skip ci] * [embedded-app] Remove StepZilla, use custom component (#747) * [embedded-app] Remove StepZilla, use custom component * Use default 'website' for embedded jss app's layout service config * Added type="button" on nav buttons to prevent page reload on click * Update after review Co-authored-by: Adam Brauer <[email protected]> * version v19.0.0-canary.21 [skip ci] * [Horizon] [samples] Added wrapping div to ContentBlock component for all frameworks (consistent with Vue) and required for Horizon editor compatibility (#752) * version v19.0.0-canary.22 [skip ci] * [Security] Latest SAST Scanning Results on v18.0.0 - highs (#748) * add updated package-lock.json to Vue sample * local peacock settings * upgrade high vuln packages in nextjs package * fix high vulns for sitecore-jss package * fix high vulns for packages in sitecore-jss-cli package * fix high vuln packages in dev-tools * fix high vulns for proxy package * fix high vulns for react package * fix high fulns for react-forms package * fix high vulns in rendering-host package * fix high vluns for tracking package * fix high vulns for update-package * fix high vulns for vue package * fix high vulns in pipelines package * undo change to settings.json * fix some high vulns in base package * upgrade trim-newlines and change to devDependency * fix high vulns for react-sample * fix high vulns for vue sample * fix high vulns found by npm audit and veracode scans fix high vulns for sitecore-jss package fix high vulns for packages in sitecore-jss-cli package fix high vuln packages in dev-tools fix high vulns for proxy package fix high vulns for react package fix high fulns for react-forms package fix high vulns in rendering-host package fix high vluns for tracking package fix high vulns for update-package fix high vulns for vue package fix high vulns in pipelines package undo change to settings.json fix some high vulns in base package upgrade trim-newlines and change to devDependency fix high vulns for react-sample fix high vulns for vue sample * fix next package package-lock * Remove use of deprecated dataApi (#744) * Replace dataApi by RestLayoutService * update docs * Update react-native, embedded-jss-app * Remove 'default' * Changes after review * Remove redundant interfaces * Removed remaining LayoutServiceRequestOptions refs * fix 'jss-layout.service' import in angular sample Co-authored-by: Adam Brauer <[email protected]> * version v19.0.0-canary.19 [skip ci] * [Vue] regeneratorRuntime error when opening Vue app in EE (#749) * version v19.0.0-canary.20 [skip ci] * [embedded-app] Remove StepZilla, use custom component (#747) * [embedded-app] Remove StepZilla, use custom component * Use default 'website' for embedded jss app's layout service config * Added type="button" on nav buttons to prevent page reload on click * Update after review Co-authored-by: Adam Brauer <[email protected]> * version v19.0.0-canary.21 [skip ci] * add updated package-lock.json to Vue sample * local peacock settings * fix high vulns found by npm audit and veracode scans fix high vulns for sitecore-jss package fix high vulns for packages in sitecore-jss-cli package fix high vuln packages in dev-tools fix high vulns for proxy package fix high vulns for react package fix high fulns for react-forms package fix high vulns in rendering-host package fix high vluns for tracking package fix high vulns for update-package fix high vulns for vue package fix high vulns in pipelines package undo change to settings.json fix some high vulns in base package upgrade trim-newlines and change to devDependency fix high vulns for react-sample fix high vulns for vue sample * Fix nextjs package * Fix react and next package-lock issues * trim-newline package set as dev:true Co-authored-by: Illia Kovalenko <[email protected]> Co-authored-by: Adam Brauer <[email protected]> Co-authored-by: Automated Build <[email protected]> * [samples] Replace dictionary calls by RestDictionaryService (#750) * Use RestDictionaryService * Remove fetch-backend dependency * Update package.lock * Updates after review * version v19.0.0-canary.23 [skip ci] * Use consistent TS version (#755) * Push * Update *-lock files, update version for nextjs sample * Remove skipLibCheck option * Fix `querystring` lib error types for sitecore-jss-angular * version v19.0.0-canary.24 [skip ci] * Remove '/dist' path from pathRewriteExcludeRoutes (#756) * [High priority packages + samples] Avoid use of 'any' for TypeScript definitions (#759) * Remove `any` from sitecore-jss * Remove 'any' from sitecore-jss-angular * Push changes * push changes * Push last changes * version v19.0.0-canary.25 [skip ci] * [Focused Improvements] .eslintrc updates (#760) * Modularized package .eslintrc each package extends the base repo's .eslintrc. typescript and react configs have been pulled out into their own eslint-config files in a new eslint-config directory at the repo root. This should make linting easier to maintain when adding additional frameworks, and will necessitate less file changes in the future. * Updated disable-next-line comments to work with new structure * Line endings added * Readd mistakenly removed rules, remove redudent extends * Remove trailing comma * Fixed linebreak-style rule * Revert no-unused-vars change * Add newlines to package*.json in root, also trimlines dev: true * Revert ignorePattern * Remove parser options * version v19.0.0-canary.26 [skip ci] * [JSS] Compile and publish all base package as ESM (#758) * Updated tsconfig to build both esm and cjs modules * Updated tsconfig to build both esm and cjs modules * Update angular-schematics package to build cjs and esm module * Update cli package to build cjs and esm module * Update dev-tools package to build cjs and esm module * Update forms package to build cjs and esm module * Update manifest package to build cjs and esm module * Update proxy package to build cjs and esm module * Update react package to build cjs and esm module * Update react-forms package to build cjs and esm module * Update rendering-host package to build cjs and esm module * Update tracking package to build cjs and esm module * Update update package to build cjs and esm module * Update vue package to build cjs and esm module * Update pipelines package to build cjs and esm module * Remove sitecore-jss package from allowedCommonJsDependencies array * Fix cli package bin directory path * Change entrypoint in package.json to the cli.js file in cli package * Add newline to end of tsconfig-esm files * Consolidate extra tsconfigs in cli package * Use named exports in index.ts currently, react-native's tests are setup to use jest, which do not support `export * from ...` syntax. So I am changing index.ts to use named exports, expecting this to change when we add sub-modules. * version v19.0.0-canary.27 [skip ci] * [Bug] npm install fails for sample apps (#762) * Updated tsconfig to build both esm and cjs modules * Updated tsconfig to build both esm and cjs modules * Update angular-schematics package to build cjs and esm module * Update cli package to build cjs and esm module * Update dev-tools package to build cjs and esm module * Update forms package to build cjs and esm module * Update manifest package to build cjs and esm module * Update proxy package to build cjs and esm module * Update react package to build cjs and esm module * Update react-forms package to build cjs and esm module * Update rendering-host package to build cjs and esm module * Update tracking package to build cjs and esm module * Update update package to build cjs and esm module * Update vue package to build cjs and esm module * Update pipelines package to build cjs and esm module * Remove sitecore-jss package from allowedCommonJsDependencies array * Fix cli package bin directory path * Change entrypoint in package.json to the cli.js file in cli package * Add newline to end of tsconfig-esm files * Consolidate extra tsconfigs in cli package * Use named exports in index.ts currently, react-native's tests are setup to use jest, which do not support `export * from ...` syntax. So I am changing index.ts to use named exports, expecting this to change when we add sub-modules. * Removed extra tsconfig file from cli * Fix dev-tools bin location in package.json also aligned the tsconfig-esm with cli package * version v19.0.0-canary.28 [skip ci] * [Angular] jss deploy files (jss deploy app) commands fails for angular sample app (#764) * version v19.0.0-canary.29 [skip ci] * Update path to jss-create module (#765) * version v19.0.0-canary.30 [skip ci] * Improve unit test coverage reporting (#761) * Enable coverage script * Edit azure-pipelines script * Add nyc file * remove file * change schematics test script * change require arg * Remove script * enable coverage script * enable script * fix angular schematics coverage command * remove 'test' script * version v19.0.0-canary.31 [skip ci] * [NextJS] Add "--empty" flag (#754) * [MVC] [NextJS] Add "--empty" flag * Add log * Add strip script * changes * changes * Allow tsx * remove strip script at the end of jss-create * Changes * Extend description * Format file * Remove changes * Update doc * revert * Change `strip` to `empty` suffix by default * Add changes * change doc * Refactoring * update script * rename test * Fix tsdoc * version v19.0.0-canary.32 [skip ci] * [Dictionary Service] [Sitemap Service] Provide ability to customize jssAppTemplateId (#763) * Extend config and getAppRootId to accept jssAppTemplateId * Update tsdoc comment for jssAppTemplateId * Extend config and getAppRootId to accept jssAppTemplateId * Update tsdoc comments * Add unit test for dictionary-service * Add test for graphql-sitemap-service * Fix linting * Revert formatting changes * Removed GUID generator, hardcoded GUIDs for tests. * version v19.0.0-canary.33 [skip ci] * [sitecore-jss-react-forms] Experience Forms JSS React implementation doesn't use CSS class applied to entire form (#771) * version v19.0.0-canary.34 [skip ci] * Next.js 11 Upgrade (#768) * React update (17.0.2 required for next 11.0.2) * Use consistent @types/prop-types (causing build errors on latest react) * Update to latest @wojtekmaj/enzyme-adapter-react-17 * sitecore-jss-nextjs upgrade to next 11.0.1. All unit tests passing. * sample app next 11 dependency update * useComponentProps hook modified to handle undefined / key not found parameter. This allows us to avoid using the hook in a conditional (which is a bad practice and now being picked up by next's OOTB eslint rules: https://reactjs.org/docs/hooks-rules.html#only-call-hooks-at-the-top-level) * Accept nextjs 'PreviewData' (new type) for getEditingData parm * Fix generic type for withPlaceholder HOC * Use next/image for logo, configure publicUrl domain for image optimization * ESLint upgrade / refresh to utilize Next.js-provided config (https://nextjs.org/docs/basic-features/eslint) * Fix lint and compile issues * Fix "warning Unexpected default export of anonymous function import/no-anonymous-default-export" for manifest files * Enable React Strict Mode (recommended) * Revert use of next/image (not editor-friendly nor export-friendly) * Remove SSR notFound workaround (fixed in latest Nextjs) #597 * Refresh custom _error component - make it clear this covers both server and client vs the custom 500 page which only covers server. * Cypress tests passing! Removed commented out nextjs config since PORT env is now fully supported: https://nextjs.org/docs/upgrading#port-is-now-supported-for-next-dev-and-next-start * formatting / typos * version v19.0.0-canary.35 [skip ci] * [MVC Static Generation] New "empty" starter (2) (#776) * Reverse order of remove boilerplate directions When following the current order, the component will error after step 1 and it is no longer possible to follow the remaining steps * Update regex to handle jsx style comments & unit test * Strip dead links from Layout.tsx when using --empty * Remove unused type * Revert * Revert line * Match indentation * version v19.0.0-canary.36 [skip ci] * Update RAV samples to work with `fetchWith` create option (#773) * Add --fetchWith to Vue sample * Removed prerender check in if statement * Use correct file extensions * Fix filename * Update names in imports/exports * Update config path * Refactored graphql components: vue Vue's graphql ConnectedDemo query and components are now in line with the newest schema. The GraphQL config in sitecore/config has been removed as well. * Extract services into factory patern - ng * Remove unused method getPlaceholderData - ng * Update ng graphQL components for edge schema * Fix lint - ng * Add comment about root item ID to ng dictionary service * Rename some variables * Refactor react services to use factory pattern * Refactor components that use an instance of the service factories * Mend transcription errors * Update jss-create - react * Refactor graphql components to use edge schema - react * Add the call to fetchWith in jss-create - ng, react * Fix typo in variable * Fix typo * Fix filepath - react * Import chalk to jss-create - ng * Update 'did you know' - ng * Update 'did you know' - vue * Fix filename - ng * Update graphql endpoint in RAV package.json * Update headless-ssr-experience-edge readme * Remove 'legacy' gql config - ng, react * Fix options * Remove querystring param from generate-config script - RAV * Update GraphQL Integrated Demo query - RAV * Add 'jss' and 'default' config patches and configName to rest layout services * Update GraphQL endpoint in RAV sitecore configs * Update path to sample2 url - react * Add api key to graphql header also jss-create now sets credential header to 'omit' when --fetchWith graphql is used - react * Update GraphQLData.js to accept language variable - react * Update angular graphql angular graphql.module and graphql.service updated to accept language variable, set proper header, and set withCredentials to false when fetching with graphql * Update vue GraphQL components to accept language variable * Add instance of factory - vue * Add sc_apikey header to GraphQLClientFactory - vue * Update jss-create to set credentials - vue * Update node-headless-ssr-experience-edge README * Revert analytics: false * Fix config file formatting * Remove sneaky console.log 🐱👤 * Create instance of dictionary service - vue * Add mistakenly removed comment from configs * Update misleading comment about sc_apikey header * Remove setCredentials * Remove note in headless-ssr-ee readme * Hardcode omit/false credentials for GraphQL client * Actually remove credentials header 🙃 * Apply proper formatting to XML configs * version v19.0.0-canary.37 [skip ci] * [React] [Nextjs] Fix double rendering (#775) * Add changes * Update package-lock * Update test * Remove layoutData * version v19.0.0-canary.38 [skip ci] * [NextJs] Fix build / lint errors on jss create (#778) * Added missing @typescript-eslint/eslint-plugin dependency * Fix prettier/lint errors in Layout.tsx * version v19.0.0-canary.39 [skip ci] * Fix typo in jss-create - react (#782) * version v19.0.0-canary.40 [skip ci] * [Angular] Fix typescript errors (#777) * [Angular] Fix typescript errors * Set requireArg `null` when don't need to execute config file * version v19.0.0-canary.41 [skip ci] * Added CHANGELOG * version v19.0.0-canary.42 [skip ci] * 🕷[React][Sample] Typo in sitecore config (#783) * Fix typo in sitecore config - react * Remove console.log 🐱👤 * version v19.0.0-canary.43 [skip ci] * 493396 [maintenance] [react] Remove obsolete poc code from sample (#784) * version v19.0.0-canary.44 [skip ci] * Update RAV configs to include layoutServiceConfiguration (#785) * version v19.0.0-canary.45 [skip ci] * Extra check for window-level Horizon chrome reset function (#786) * version v19.0.0-canary.46 [skip ci] * [NextJS] Prevent webpack-5 to throw error for `sitecore-import.json` when app started first time (#788) * version v19.0.0-canary.47 [skip ci] * [sitecore-jss] Import lodash correctly (#791) * version v19.0.0-canary.48 [skip ci] * [sitecore-jss-cli] RAV fetchWith uses old GraphQl endpoint path in package.json (#792) * [sitecore-jss-cli] RAV fetchWith uses old GraphQl endpoint path in package.json * Apply default app name, remove obsolete code * Make replaceName required * Update jsdoc * Revert unit tests * version v19.0.0-canary.49 [skip ci] * 🕷[Dev][JSS 19][Angular] Fix jss scaffold issue (#794) * Removed esm build for angular-schematics package * Revert tsconfig.json to before esm modules * version v19.0.0-canary.50 [skip ci] * Update disconnected server and manifest manager options to acccept null for requireArg (#795) * version v19.0.0-canary.51 [skip ci] * Backfill changelog to versions up to 11.0.0 (#797) * version v19.0.0-canary.52 [skip ci] * v19 CHANGELOG audit / refresh. Other adjustments for consistency. (#798) * version v19.0.0-canary.53 [skip ci] * CHANGELOG adjustments for Horizon compatibility clarity (only Next.js sample) * version v19.0.0-canary.54 [skip ci] * Removed RAV Sitecore config patch for <IncludeServerUrlInMediaUrls>false</IncludeServerUrlInMediaUrls>. This should only be disabled for Next.js and SSR Proxy. (#802) * version v19.0.0-canary.55 [skip ci] * Fix cannot find a differ... error (#803) * Fix Vue sample RestLayoutService config (use 'apiHost', not 'endpoint') (#804) * version v19.0.0-canary.56 [skip ci] * [NextJs][Regression] Custom Components cannot be added using Horizon (#807) * Fix update-graphql-fragment-data react sample * Add optional chaining to fields of scaffolded components * Revert "Fix update-graphql-fragment-data react sample" This reverts commit 467600f. * Refactor component-src template to use withDatasourceCheck() * version v19.0.0-canary.57 [skip ci] * [RAV][Regression] jss graphql:update throws errors (#806) * Fix update-graphql-fragment-data react sample * Fix vue graphql:update * Fix angular graphql:update Co-authored-by: Adam Brauer <[email protected]> * version v19.0.0-canary.58 [skip ci] * [React] Set `changeOrigin: true` for proxied Sitecore requests in connected mode (#808) * Set changeOrigin: true for proxied Sitecore requests in React connected mode - resolves 504 (Gateway Timeout) errors * Add changelog * version v19.0.0-canary.59 [skip ci] * Handling of not found layout service requests in Angular sample. The new Rest/GraphQLLayoutService implementations do not return HTTP 404 status. Instead, a 200 is returned and a missing route value signifies not found. (#809) * version v19.0.0-canary.60 [skip ci] * [VUE] [Regression] Internal Server error for Vue + --fetchWith GraphQL + node-headless-SSR-Experience-Edge (#812) * Lint config * Remove serverBundle.defaultLanguage as default language option as it does not exist. * Add 'en' as default fallback langauge * version v19.0.0-canary.61 [skip ci] * Generate ref docs for JSS and JSS for Next.js packages (#829) Co-authored-by: Anca Emcken <[email protected]> * version v19.0.0-canary.62 [skip ci] * Migrate off of deprecated Ubuntu 16.0.4 VM image * version v19.0.0-canary.63 [skip ci] Co-authored-by: Automated Build <[email protected]> Co-authored-by: Adam Brauer <[email protected]> Co-authored-by: Anca Emcken <[email protected]> Co-authored-by: illiakovalenko <[email protected]> Co-authored-by: Illia Kovalenko <[email protected]> Co-authored-by: Coby Sher <[email protected]> Co-authored-by: Anca Emcken <[email protected]>
Description / Motivation
Sitecore Headless Services was recently updated to return
number
instead ofstring
type for number fields. This fix updates our SDKs to properly handle.Testing Details
Unit tests added. Manual testing for Next.js / React including editing in Experience Editor and Horizon.
Types of changes
/docs
directory)