@erudit-js/core 4.0.1 → 4.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/eruditConfig/asideMajor.d.ts +16 -0
- package/dist/eruditConfig/config.d.ts +9 -4
- package/dist/eruditConfig/favicons.d.ts +8 -0
- package/dist/prose/link.d.ts +4 -4
- package/dist/prose/link.js +1 -1
- package/package.json +1 -1
- package/dist/eruditConfig/links.d.ts +0 -6
- package/dist/eruditConfig/site.d.ts +0 -23
- /package/dist/eruditConfig/{links.js → asideMajor.js} +0 -0
- /package/dist/eruditConfig/{site.js → favicons.js} +0 -0
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export interface EruditAsideMajor {
|
|
2
|
+
/** Info block at the top of aside. */
|
|
3
|
+
siteInfo?: Partial<{
|
|
4
|
+
title: string;
|
|
5
|
+
short: string | false;
|
|
6
|
+
logotype: string | false;
|
|
7
|
+
}>;
|
|
8
|
+
/** Any links that are displayed at the bottom of "Pages" pane. */
|
|
9
|
+
customLinks?: EruditCustomLinks;
|
|
10
|
+
}
|
|
11
|
+
export interface EruditCustomLink {
|
|
12
|
+
label: string;
|
|
13
|
+
href: string;
|
|
14
|
+
icon?: string;
|
|
15
|
+
}
|
|
16
|
+
export type EruditCustomLinks = EruditCustomLink[] | undefined;
|
|
@@ -5,25 +5,30 @@ import type { EruditSponsors } from '../sponsor.js';
|
|
|
5
5
|
import type { EruditAdsBanners } from './ads.js';
|
|
6
6
|
import type { EruditAnalytics } from './analytics.js';
|
|
7
7
|
import type { EruditDebug } from './debug.js';
|
|
8
|
-
import type { EruditCustomLinks } from './links.js';
|
|
9
8
|
import type { EruditRepository } from './repository.js';
|
|
10
9
|
import type { EruditSeo } from './seo.js';
|
|
11
|
-
import type { EruditSite } from './site.js';
|
|
12
10
|
import type { EruditLanguage } from './language.js';
|
|
13
11
|
import type { EruditElements } from './elements.js';
|
|
14
12
|
import type { EruditContributors } from '../contributor.js';
|
|
13
|
+
import type { EruditAsideMajor } from './asideMajor.js';
|
|
14
|
+
import type { EruditFavicons } from './favicons.js';
|
|
15
15
|
export interface EruditConfig {
|
|
16
16
|
language?: EruditLanguage;
|
|
17
17
|
debug?: EruditDebug;
|
|
18
18
|
analytics?: EruditAnalytics;
|
|
19
19
|
ads?: EruditAdsBanners;
|
|
20
|
-
site
|
|
20
|
+
/** Settings for site major (left) aside. */
|
|
21
|
+
asideMajor?: EruditAsideMajor;
|
|
22
|
+
favicon?: EruditFavicons;
|
|
23
|
+
style?: Partial<{
|
|
24
|
+
brandColor: string;
|
|
25
|
+
}>;
|
|
26
|
+
loadingSvg?: string;
|
|
21
27
|
indexPage?: EruditIndexPage;
|
|
22
28
|
contributors?: EruditContributors;
|
|
23
29
|
sponsors?: EruditSponsors;
|
|
24
30
|
seo?: EruditSeo;
|
|
25
31
|
repository?: EruditRepository;
|
|
26
|
-
customLinks?: EruditCustomLinks;
|
|
27
32
|
elements?: EruditElements;
|
|
28
33
|
countElements?: (string | string[])[];
|
|
29
34
|
/**
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { TopicPart } from '../content/topic.js';
|
|
2
|
+
import type { ContentType } from '../content/type.js';
|
|
3
|
+
export type EruditFavicons = Partial<{
|
|
4
|
+
default?: string;
|
|
5
|
+
} & Exclude<Record<ContentType, string>, 'topic'> & Record<TopicPart, string>> | string;
|
|
6
|
+
export type EruditFaviconsResolved = Partial<{
|
|
7
|
+
default: string;
|
|
8
|
+
} & Exclude<Record<ContentType, string>, 'topic'> & Record<TopicPart, string>>;
|
package/dist/prose/link.d.ts
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import type { ContentPointer } from '../content/pointer.js';
|
|
2
|
-
export declare const proseLinkTypes: readonly ["
|
|
2
|
+
export declare const proseLinkTypes: readonly ["external", "contentItem", "unique"];
|
|
3
3
|
export type ProseLinkType = (typeof proseLinkTypes)[number];
|
|
4
4
|
export declare function isProseLinkType(value: unknown): value is ProseLinkType;
|
|
5
5
|
interface BaseProseLink {
|
|
6
6
|
type: ProseLinkType;
|
|
7
7
|
}
|
|
8
|
-
export interface
|
|
9
|
-
type: '
|
|
8
|
+
export interface ExternalProseLink extends BaseProseLink {
|
|
9
|
+
type: 'external';
|
|
10
10
|
href: string;
|
|
11
11
|
}
|
|
12
12
|
export interface ContentItemProseLink extends BaseProseLink {
|
|
@@ -18,5 +18,5 @@ export interface UniqueProseLink extends BaseProseLink {
|
|
|
18
18
|
contentPointer: ContentPointer;
|
|
19
19
|
uniqueName: string;
|
|
20
20
|
}
|
|
21
|
-
export type ProseLink =
|
|
21
|
+
export type ProseLink = ExternalProseLink | ContentItemProseLink | UniqueProseLink;
|
|
22
22
|
export {};
|
package/dist/prose/link.js
CHANGED
package/package.json
CHANGED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import type { TopicPart } from '../content/topic.js';
|
|
2
|
-
import type { ContentType } from '../content/type.js';
|
|
3
|
-
export type EruditSiteFaviconConfig = Partial<{
|
|
4
|
-
default?: string;
|
|
5
|
-
} & Exclude<Record<ContentType, string>, 'topic'> & Record<TopicPart, string>> | string;
|
|
6
|
-
export type EruditSiteFaviconResolved = Partial<{
|
|
7
|
-
default: string;
|
|
8
|
-
} & Exclude<Record<ContentType, string>, 'topic'> & Record<TopicPart, string>>;
|
|
9
|
-
export type EruditSite = Partial<{
|
|
10
|
-
title: string;
|
|
11
|
-
short: string | false;
|
|
12
|
-
/**
|
|
13
|
-
* - `string` — url to your logotype (use `projectPublic` to target path inside `public` directory)
|
|
14
|
-
* - `false` — do not show logotype
|
|
15
|
-
* - falsy (`0`, `undefined`, `null`, `""` and etc.) — use default Erudit logotype
|
|
16
|
-
*/
|
|
17
|
-
logotype: string | false;
|
|
18
|
-
favicon: EruditSiteFaviconConfig;
|
|
19
|
-
style: Partial<{
|
|
20
|
-
brandColor: string;
|
|
21
|
-
}>;
|
|
22
|
-
loadingSvg: string;
|
|
23
|
-
}>;
|
|
File without changes
|
|
File without changes
|