@gitbook/api 0.117.1 → 0.119.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/client.d.ts +25 -5
- package/dist/index.cjs +10 -2
- package/dist/index.js +9 -2
- package/package.json +1 -1
- package/spec/openapi.json +50 -14
- package/spec/openapi.yaml +31 -9
package/dist/client.d.ts
CHANGED
|
@@ -1374,7 +1374,9 @@ export interface RevisionPageLayoutOptions {
|
|
|
1374
1374
|
}
|
|
1375
1375
|
export interface RevisionPageDocumentCover {
|
|
1376
1376
|
/** Content reference pointing to the source image. */
|
|
1377
|
-
ref?: ContentRefFile;
|
|
1377
|
+
ref?: ContentRefFile | ContentRefURL;
|
|
1378
|
+
/** Content reference pointing to the source image for dark mode. */
|
|
1379
|
+
refDark?: ContentRefFile | ContentRefURL;
|
|
1378
1380
|
/** Vertical position of the cover image. */
|
|
1379
1381
|
yPos: number;
|
|
1380
1382
|
}
|
|
@@ -4682,7 +4684,17 @@ export interface CustomizationTint {
|
|
|
4682
4684
|
}
|
|
4683
4685
|
export declare enum CustomizationCorners {
|
|
4684
4686
|
Straight = "straight",
|
|
4685
|
-
Rounded = "rounded"
|
|
4687
|
+
Rounded = "rounded",
|
|
4688
|
+
Circular = "circular"
|
|
4689
|
+
}
|
|
4690
|
+
/**
|
|
4691
|
+
* The degree of visual depth (through shadows, gradients and elevation effects) of elements on the site.
|
|
4692
|
+
* - `subtle`: Subtle shadows and minimal elevation.
|
|
4693
|
+
* - `flat`: Flat elements, no shadows and no elevation.
|
|
4694
|
+
*/
|
|
4695
|
+
export declare enum CustomizationDepth {
|
|
4696
|
+
Subtle = "subtle",
|
|
4697
|
+
Flat = "flat"
|
|
4686
4698
|
}
|
|
4687
4699
|
/**
|
|
4688
4700
|
* The style used for regular links in the main content, header and footer. Sidebar items are styled separately.
|
|
@@ -4832,6 +4844,12 @@ export interface SiteCustomizationSettings {
|
|
|
4832
4844
|
warningColor: CustomizationThemedColor;
|
|
4833
4845
|
dangerColor: CustomizationThemedColor;
|
|
4834
4846
|
corners: CustomizationCorners;
|
|
4847
|
+
/**
|
|
4848
|
+
* The degree of visual depth (through shadows, gradients and elevation effects) of elements on the site.
|
|
4849
|
+
* - `subtle`: Subtle shadows and minimal elevation.
|
|
4850
|
+
* - `flat`: Flat elements, no shadows and no elevation.
|
|
4851
|
+
*/
|
|
4852
|
+
depth: CustomizationDepth;
|
|
4835
4853
|
/**
|
|
4836
4854
|
* The style used for regular links in the main content, header and footer. Sidebar items are styled separately.
|
|
4837
4855
|
* - `default`: Links are colored in the primary color and feature an underline in the same color.
|
|
@@ -11365,12 +11383,12 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
11365
11383
|
* No description
|
|
11366
11384
|
*
|
|
11367
11385
|
* @tags sites
|
|
11368
|
-
* @name
|
|
11369
|
-
* @summary
|
|
11386
|
+
* @name UpdateSiteAdaptiveSchema
|
|
11387
|
+
* @summary Update the JSON schema of the attributes expected for an Adaptive content site visitor.
|
|
11370
11388
|
* @request PUT:/orgs/{organizationId}/sites/{siteId}/adaptive-schema
|
|
11371
11389
|
* @secure
|
|
11372
11390
|
*/
|
|
11373
|
-
|
|
11391
|
+
updateSiteAdaptiveSchema: (organizationId: string, siteId: string, data: {
|
|
11374
11392
|
/** The JSON schema to set on the site. */
|
|
11375
11393
|
jsonSchema: SiteAdaptiveJSONSchema;
|
|
11376
11394
|
}, params?: RequestParams) => Promise<HttpResponse<SiteAdaptiveSchema, Error | {
|
|
@@ -11993,6 +12011,8 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
|
|
|
11993
12011
|
tint?: CustomizationTint | null;
|
|
11994
12012
|
/** The style of the corners to use. Set to null to reset the override. */
|
|
11995
12013
|
corners?: CustomizationCorners | null;
|
|
12014
|
+
/** The depth of elements on the site. Set to null to reset the override. */
|
|
12015
|
+
depth?: CustomizationDepth | null;
|
|
11996
12016
|
/** The style for links to use. Set to null to reset the override. */
|
|
11997
12017
|
links?: CustomizationLinksStyle | null;
|
|
11998
12018
|
/** The font family to use for the content. Set to null to reset the override. */
|
package/dist/index.cjs
CHANGED
|
@@ -206,6 +206,7 @@ __export(src_exports, {
|
|
|
206
206
|
CustomizationBackground: () => CustomizationBackground,
|
|
207
207
|
CustomizationCorners: () => CustomizationCorners,
|
|
208
208
|
CustomizationDefaultFont: () => CustomizationDefaultFont,
|
|
209
|
+
CustomizationDepth: () => CustomizationDepth,
|
|
209
210
|
CustomizationHeaderPreset: () => CustomizationHeaderPreset,
|
|
210
211
|
CustomizationIconsStyle: () => CustomizationIconsStyle,
|
|
211
212
|
CustomizationLinksStyle: () => CustomizationLinksStyle,
|
|
@@ -270,7 +271,7 @@ module.exports = __toCommonJS(src_exports);
|
|
|
270
271
|
|
|
271
272
|
// package.json
|
|
272
273
|
var name = "@gitbook/api";
|
|
273
|
-
var version = "0.
|
|
274
|
+
var version = "0.119.0";
|
|
274
275
|
|
|
275
276
|
// src/client.ts
|
|
276
277
|
var import_event_iterator = __toESM(require_node(), 1);
|
|
@@ -732,8 +733,14 @@ var CustomizationTheme = /* @__PURE__ */ ((CustomizationTheme2) => {
|
|
|
732
733
|
var CustomizationCorners = /* @__PURE__ */ ((CustomizationCorners2) => {
|
|
733
734
|
CustomizationCorners2["Straight"] = "straight";
|
|
734
735
|
CustomizationCorners2["Rounded"] = "rounded";
|
|
736
|
+
CustomizationCorners2["Circular"] = "circular";
|
|
735
737
|
return CustomizationCorners2;
|
|
736
738
|
})(CustomizationCorners || {});
|
|
739
|
+
var CustomizationDepth = /* @__PURE__ */ ((CustomizationDepth2) => {
|
|
740
|
+
CustomizationDepth2["Subtle"] = "subtle";
|
|
741
|
+
CustomizationDepth2["Flat"] = "flat";
|
|
742
|
+
return CustomizationDepth2;
|
|
743
|
+
})(CustomizationDepth || {});
|
|
737
744
|
var CustomizationLinksStyle = /* @__PURE__ */ ((CustomizationLinksStyle2) => {
|
|
738
745
|
CustomizationLinksStyle2["Default"] = "default";
|
|
739
746
|
CustomizationLinksStyle2["Accent"] = "accent";
|
|
@@ -3081,7 +3088,7 @@ var Api = class extends HttpClient {
|
|
|
3081
3088
|
format: "json",
|
|
3082
3089
|
...params
|
|
3083
3090
|
}),
|
|
3084
|
-
|
|
3091
|
+
updateSiteAdaptiveSchema: (organizationId, siteId, data, params = {}) => this.request({
|
|
3085
3092
|
path: `/orgs/${organizationId}/sites/${siteId}/adaptive-schema`,
|
|
3086
3093
|
method: "PUT",
|
|
3087
3094
|
body: data,
|
|
@@ -3695,6 +3702,7 @@ var GitBookAPI = class extends Api {
|
|
|
3695
3702
|
CustomizationBackground,
|
|
3696
3703
|
CustomizationCorners,
|
|
3697
3704
|
CustomizationDefaultFont,
|
|
3705
|
+
CustomizationDepth,
|
|
3698
3706
|
CustomizationHeaderPreset,
|
|
3699
3707
|
CustomizationIconsStyle,
|
|
3700
3708
|
CustomizationLinksStyle,
|
package/dist/index.js
CHANGED
|
@@ -172,7 +172,7 @@ var require_node = __commonJS({
|
|
|
172
172
|
|
|
173
173
|
// package.json
|
|
174
174
|
var name = "@gitbook/api";
|
|
175
|
-
var version = "0.
|
|
175
|
+
var version = "0.119.0";
|
|
176
176
|
|
|
177
177
|
// src/client.ts
|
|
178
178
|
var import_event_iterator = __toESM(require_node(), 1);
|
|
@@ -634,8 +634,14 @@ var CustomizationTheme = /* @__PURE__ */ ((CustomizationTheme2) => {
|
|
|
634
634
|
var CustomizationCorners = /* @__PURE__ */ ((CustomizationCorners2) => {
|
|
635
635
|
CustomizationCorners2["Straight"] = "straight";
|
|
636
636
|
CustomizationCorners2["Rounded"] = "rounded";
|
|
637
|
+
CustomizationCorners2["Circular"] = "circular";
|
|
637
638
|
return CustomizationCorners2;
|
|
638
639
|
})(CustomizationCorners || {});
|
|
640
|
+
var CustomizationDepth = /* @__PURE__ */ ((CustomizationDepth2) => {
|
|
641
|
+
CustomizationDepth2["Subtle"] = "subtle";
|
|
642
|
+
CustomizationDepth2["Flat"] = "flat";
|
|
643
|
+
return CustomizationDepth2;
|
|
644
|
+
})(CustomizationDepth || {});
|
|
639
645
|
var CustomizationLinksStyle = /* @__PURE__ */ ((CustomizationLinksStyle2) => {
|
|
640
646
|
CustomizationLinksStyle2["Default"] = "default";
|
|
641
647
|
CustomizationLinksStyle2["Accent"] = "accent";
|
|
@@ -2983,7 +2989,7 @@ var Api = class extends HttpClient {
|
|
|
2983
2989
|
format: "json",
|
|
2984
2990
|
...params
|
|
2985
2991
|
}),
|
|
2986
|
-
|
|
2992
|
+
updateSiteAdaptiveSchema: (organizationId, siteId, data, params = {}) => this.request({
|
|
2987
2993
|
path: `/orgs/${organizationId}/sites/${siteId}/adaptive-schema`,
|
|
2988
2994
|
method: "PUT",
|
|
2989
2995
|
body: data,
|
|
@@ -3596,6 +3602,7 @@ export {
|
|
|
3596
3602
|
CustomizationBackground,
|
|
3597
3603
|
CustomizationCorners,
|
|
3598
3604
|
CustomizationDefaultFont,
|
|
3605
|
+
CustomizationDepth,
|
|
3599
3606
|
CustomizationHeaderPreset,
|
|
3600
3607
|
CustomizationIconsStyle,
|
|
3601
3608
|
CustomizationLinksStyle,
|
package/package.json
CHANGED
package/spec/openapi.json
CHANGED
|
@@ -12040,8 +12040,8 @@
|
|
|
12040
12040
|
}
|
|
12041
12041
|
},
|
|
12042
12042
|
"put": {
|
|
12043
|
-
"operationId": "
|
|
12044
|
-
"summary": "
|
|
12043
|
+
"operationId": "updateSiteAdaptiveSchema",
|
|
12044
|
+
"summary": "Update the JSON schema of the attributes expected for an Adaptive content site visitor.",
|
|
12045
12045
|
"tags": [
|
|
12046
12046
|
"sites"
|
|
12047
12047
|
],
|
|
@@ -12088,16 +12088,6 @@
|
|
|
12088
12088
|
}
|
|
12089
12089
|
}
|
|
12090
12090
|
},
|
|
12091
|
-
"201": {
|
|
12092
|
-
"description": "The site adaptive schema has been created.",
|
|
12093
|
-
"content": {
|
|
12094
|
-
"application/json": {
|
|
12095
|
-
"schema": {
|
|
12096
|
-
"$ref": "#/components/schemas/SiteAdaptiveSchema"
|
|
12097
|
-
}
|
|
12098
|
-
}
|
|
12099
|
-
}
|
|
12100
|
-
},
|
|
12101
12091
|
"400": {
|
|
12102
12092
|
"$ref": "#/components/responses/BadRequestError"
|
|
12103
12093
|
},
|
|
@@ -14129,6 +14119,21 @@
|
|
|
14129
14119
|
}
|
|
14130
14120
|
]
|
|
14131
14121
|
},
|
|
14122
|
+
"depth": {
|
|
14123
|
+
"description": "The depth of elements on the site. Set to null to reset the override.",
|
|
14124
|
+
"oneOf": [
|
|
14125
|
+
{
|
|
14126
|
+
"$ref": "#/components/schemas/CustomizationDepth"
|
|
14127
|
+
},
|
|
14128
|
+
{
|
|
14129
|
+
"type": "string",
|
|
14130
|
+
"nullable": true,
|
|
14131
|
+
"enum": [
|
|
14132
|
+
null
|
|
14133
|
+
]
|
|
14134
|
+
}
|
|
14135
|
+
]
|
|
14136
|
+
},
|
|
14132
14137
|
"links": {
|
|
14133
14138
|
"description": "The style for links to use. Set to null to reset the override.",
|
|
14134
14139
|
"oneOf": [
|
|
@@ -22011,7 +22016,25 @@
|
|
|
22011
22016
|
"properties": {
|
|
22012
22017
|
"ref": {
|
|
22013
22018
|
"description": "Content reference pointing to the source image.",
|
|
22014
|
-
"
|
|
22019
|
+
"oneOf": [
|
|
22020
|
+
{
|
|
22021
|
+
"$ref": "#/components/schemas/ContentRefFile"
|
|
22022
|
+
},
|
|
22023
|
+
{
|
|
22024
|
+
"$ref": "#/components/schemas/ContentRefURL"
|
|
22025
|
+
}
|
|
22026
|
+
]
|
|
22027
|
+
},
|
|
22028
|
+
"refDark": {
|
|
22029
|
+
"description": "Content reference pointing to the source image for dark mode.",
|
|
22030
|
+
"oneOf": [
|
|
22031
|
+
{
|
|
22032
|
+
"$ref": "#/components/schemas/ContentRefFile"
|
|
22033
|
+
},
|
|
22034
|
+
{
|
|
22035
|
+
"$ref": "#/components/schemas/ContentRefURL"
|
|
22036
|
+
}
|
|
22037
|
+
]
|
|
22015
22038
|
},
|
|
22016
22039
|
"yPos": {
|
|
22017
22040
|
"description": "Vertical position of the cover image.",
|
|
@@ -31767,7 +31790,16 @@
|
|
|
31767
31790
|
"type": "string",
|
|
31768
31791
|
"enum": [
|
|
31769
31792
|
"straight",
|
|
31770
|
-
"rounded"
|
|
31793
|
+
"rounded",
|
|
31794
|
+
"circular"
|
|
31795
|
+
]
|
|
31796
|
+
},
|
|
31797
|
+
"CustomizationDepth": {
|
|
31798
|
+
"type": "string",
|
|
31799
|
+
"description": "The degree of visual depth (through shadows, gradients and elevation effects) of elements on the site.\n- `subtle`: Subtle shadows and minimal elevation.\n- `flat`: Flat elements, no shadows and no elevation.\n",
|
|
31800
|
+
"enum": [
|
|
31801
|
+
"subtle",
|
|
31802
|
+
"flat"
|
|
31771
31803
|
]
|
|
31772
31804
|
},
|
|
31773
31805
|
"CustomizationLinksStyle": {
|
|
@@ -32035,6 +32067,9 @@
|
|
|
32035
32067
|
"corners": {
|
|
32036
32068
|
"$ref": "#/components/schemas/CustomizationCorners"
|
|
32037
32069
|
},
|
|
32070
|
+
"depth": {
|
|
32071
|
+
"$ref": "#/components/schemas/CustomizationDepth"
|
|
32072
|
+
},
|
|
32038
32073
|
"links": {
|
|
32039
32074
|
"$ref": "#/components/schemas/CustomizationLinksStyle"
|
|
32040
32075
|
},
|
|
@@ -32075,6 +32110,7 @@
|
|
|
32075
32110
|
"warningColor",
|
|
32076
32111
|
"dangerColor",
|
|
32077
32112
|
"corners",
|
|
32113
|
+
"depth",
|
|
32078
32114
|
"links",
|
|
32079
32115
|
"font",
|
|
32080
32116
|
"background",
|
package/spec/openapi.yaml
CHANGED
|
@@ -6843,8 +6843,8 @@ paths:
|
|
|
6843
6843
|
default:
|
|
6844
6844
|
$ref: "#/components/responses/UnexpectedError"
|
|
6845
6845
|
put:
|
|
6846
|
-
operationId:
|
|
6847
|
-
summary:
|
|
6846
|
+
operationId: updateSiteAdaptiveSchema
|
|
6847
|
+
summary: Update the JSON schema of the attributes expected for an Adaptive content site visitor.
|
|
6848
6848
|
tags:
|
|
6849
6849
|
- sites
|
|
6850
6850
|
security:
|
|
@@ -6871,12 +6871,6 @@ paths:
|
|
|
6871
6871
|
application/json:
|
|
6872
6872
|
schema:
|
|
6873
6873
|
$ref: "#/components/schemas/SiteAdaptiveSchema"
|
|
6874
|
-
"201":
|
|
6875
|
-
description: The site adaptive schema has been created.
|
|
6876
|
-
content:
|
|
6877
|
-
application/json:
|
|
6878
|
-
schema:
|
|
6879
|
-
$ref: "#/components/schemas/SiteAdaptiveSchema"
|
|
6880
6874
|
"400":
|
|
6881
6875
|
$ref: "#/components/responses/BadRequestError"
|
|
6882
6876
|
default:
|
|
@@ -7984,6 +7978,14 @@ paths:
|
|
|
7984
7978
|
nullable: true
|
|
7985
7979
|
enum:
|
|
7986
7980
|
- null
|
|
7981
|
+
depth:
|
|
7982
|
+
description: The depth of elements on the site. Set to null to reset the override.
|
|
7983
|
+
oneOf:
|
|
7984
|
+
- $ref: "#/components/schemas/CustomizationDepth"
|
|
7985
|
+
- type: string
|
|
7986
|
+
nullable: true
|
|
7987
|
+
enum:
|
|
7988
|
+
- null
|
|
7987
7989
|
links:
|
|
7988
7990
|
description: The style for links to use. Set to null to reset the override.
|
|
7989
7991
|
oneOf:
|
|
@@ -12978,7 +12980,14 @@ components:
|
|
|
12978
12980
|
properties:
|
|
12979
12981
|
ref:
|
|
12980
12982
|
description: Content reference pointing to the source image.
|
|
12981
|
-
|
|
12983
|
+
oneOf:
|
|
12984
|
+
- $ref: "#/components/schemas/ContentRefFile"
|
|
12985
|
+
- $ref: "#/components/schemas/ContentRefURL"
|
|
12986
|
+
refDark:
|
|
12987
|
+
description: Content reference pointing to the source image for dark mode.
|
|
12988
|
+
oneOf:
|
|
12989
|
+
- $ref: "#/components/schemas/ContentRefFile"
|
|
12990
|
+
- $ref: "#/components/schemas/ContentRefURL"
|
|
12982
12991
|
yPos:
|
|
12983
12992
|
description: Vertical position of the cover image.
|
|
12984
12993
|
type: number
|
|
@@ -19556,6 +19565,16 @@ components:
|
|
|
19556
19565
|
enum:
|
|
19557
19566
|
- straight
|
|
19558
19567
|
- rounded
|
|
19568
|
+
- circular
|
|
19569
|
+
CustomizationDepth:
|
|
19570
|
+
type: string
|
|
19571
|
+
description: |
|
|
19572
|
+
The degree of visual depth (through shadows, gradients and elevation effects) of elements on the site.
|
|
19573
|
+
- `subtle`: Subtle shadows and minimal elevation.
|
|
19574
|
+
- `flat`: Flat elements, no shadows and no elevation.
|
|
19575
|
+
enum:
|
|
19576
|
+
- subtle
|
|
19577
|
+
- flat
|
|
19559
19578
|
CustomizationLinksStyle:
|
|
19560
19579
|
type: string
|
|
19561
19580
|
description: |
|
|
@@ -19761,6 +19780,8 @@ components:
|
|
|
19761
19780
|
$ref: "#/components/schemas/CustomizationThemedColor"
|
|
19762
19781
|
corners:
|
|
19763
19782
|
$ref: "#/components/schemas/CustomizationCorners"
|
|
19783
|
+
depth:
|
|
19784
|
+
$ref: "#/components/schemas/CustomizationDepth"
|
|
19764
19785
|
links:
|
|
19765
19786
|
$ref: "#/components/schemas/CustomizationLinksStyle"
|
|
19766
19787
|
font:
|
|
@@ -19790,6 +19811,7 @@ components:
|
|
|
19790
19811
|
- warningColor
|
|
19791
19812
|
- dangerColor
|
|
19792
19813
|
- corners
|
|
19814
|
+
- depth
|
|
19793
19815
|
- links
|
|
19794
19816
|
- font
|
|
19795
19817
|
- background
|