Skip to content

Commit

Permalink
Update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
robisim74 committed Oct 28, 2020
1 parent bf5c52b commit e3415b0
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions docs/injectables/L10nDefaultLocation.html
Original file line number Diff line number Diff line change
Expand Up @@ -510,7 +510,7 @@ <h3 id="accessors">
public abstract parsePath(path: string): string | null;

/**
* This method must contain the logic toget the localized segment in the path.
* This method must contain the logic to get the localized segment in the path.
* @param path The localized path
*/
public abstract getLocalizedSegment(path: string): string | null;
Expand Down Expand Up @@ -550,7 +550,7 @@ <h3 id="accessors">
public getLocalizedSegment(path: string): string | null {
for (const element of this.config.schema) {
const language &#x3D; formatLanguage(element.locale.language, this.config.format);
const regex &#x3D; new RegExp(&#x60;(\/${language}\/)|(\/${language}$)&#x60;);
const regex &#x3D; new RegExp(&#x60;(\/${language}\/)|(\/${language}$)|(\/(${language})(?&#x3D;\\?))|(\/(${language})(?&#x3D;\\#))&#x60;);
const segments &#x3D; path.match(regex);
if (segments !&#x3D; null) {
return segments[0];
Expand Down
6 changes: 3 additions & 3 deletions docs/injectables/L10nLocation.html
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ <h3 id="methods">

<tr>
<td class="col-md-4">
<div class="io-description"><p>This method must contain the logic toget the localized segment in the path.</p>
<div class="io-description"><p>This method must contain the logic to get the localized segment in the path.</p>
</div>

<div class="io-description">
Expand Down Expand Up @@ -458,7 +458,7 @@ <h3 id="methods">
public abstract parsePath(path: string): string | null;

/**
* This method must contain the logic toget the localized segment in the path.
* This method must contain the logic to get the localized segment in the path.
* @param path The localized path
*/
public abstract getLocalizedSegment(path: string): string | null;
Expand Down Expand Up @@ -498,7 +498,7 @@ <h3 id="methods">
public getLocalizedSegment(path: string): string | null {
for (const element of this.config.schema) {
const language &#x3D; formatLanguage(element.locale.language, this.config.format);
const regex &#x3D; new RegExp(&#x60;(\/${language}\/)|(\/${language}$)&#x60;);
const regex &#x3D; new RegExp(&#x60;(\/${language}\/)|(\/${language}$)|(\/(${language})(?&#x3D;\\?))|(\/(${language})(?&#x3D;\\#))&#x60;);
const segments &#x3D; path.match(regex);
if (segments !&#x3D; null) {
return segments[0];
Expand Down
4 changes: 2 additions & 2 deletions docs/js/search/search_index.js

Large diffs are not rendered by default.

0 comments on commit e3415b0

Please sign in to comment.