ag-common 0.0.374 → 0.0.375
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/api/helpers/dynamo.d.ts +1 -1
- package/dist/api/helpers/dynamo.js +7 -3
- package/dist/api/helpers/dynamoInfra.d.ts +1 -1
- package/dist/api/helpers/openApiHelpers.d.ts +2 -2
- package/dist/api/helpers/openApiHelpers.js +1 -1
- package/dist/api/helpers/s3.d.ts +2 -2
- package/dist/api/helpers/s3.js +1 -1
- package/dist/api/helpers/sqs.js +1 -1
- package/dist/api/helpers/validateOpenApi.d.ts +2 -2
- package/dist/api/helpers/validateOpenApi.js +4 -4
- package/dist/api/helpers/validations.js +2 -2
- package/dist/api/index.d.ts +1 -1
- package/dist/api/index.js +1 -1
- package/dist/api/types/index.d.ts +1 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.js +2 -2
- package/dist/ui/components/BorderGradient/index.js +10 -10
- package/dist/ui/components/Button/index.js +5 -5
- package/dist/ui/components/Chevron/index.js +1 -1
- package/dist/ui/components/Close/index.js +1 -1
- package/dist/ui/components/Confirm/Dialog.js +2 -2
- package/dist/ui/components/Confirm/Modal.js +2 -2
- package/dist/ui/components/Confirm/index.d.ts +1 -1
- package/dist/ui/components/Confirm/index.js +1 -1
- package/dist/ui/components/DropdownList/Base.js +3 -3
- package/dist/ui/components/DropdownList/Dialog.js +1 -1
- package/dist/ui/components/FlexColumn/index.js +1 -1
- package/dist/ui/components/FlexRow/index.js +1 -1
- package/dist/ui/components/Icon/index.js +3 -3
- package/dist/ui/components/Image/index.js +1 -1
- package/dist/ui/components/KebabDots/index.js +2 -2
- package/dist/ui/components/Modal/Dialog.js +1 -1
- package/dist/ui/components/Modal/Modal.d.ts +1 -1
- package/dist/ui/components/Modal/Modal.js +3 -3
- package/dist/ui/components/Modal/index.d.ts +2 -2
- package/dist/ui/components/Modal/index.js +2 -2
- package/dist/ui/components/OpenApiCodeBlock/OpenApiCodeBlock.js +4 -4
- package/dist/ui/components/OpenApiCodeBlock/curl/helpers/body.js +1 -1
- package/dist/ui/components/OpenApiCodeBlock/curl/helpers/security.js +1 -1
- package/dist/ui/components/OpenApiCodeBlock/curl/index.js +7 -7
- package/dist/ui/components/OpenApiCodeBlock/fetch/helpers/call.js +1 -1
- package/dist/ui/components/OpenApiCodeBlock/fetch/helpers/req.js +14 -14
- package/dist/ui/components/OpenApiCodeBlock/fetch/index.js +3 -3
- package/dist/ui/components/OpenApiCodeBlock/helpers/common.js +1 -1
- package/dist/ui/components/OpenApiCodeBlock/helpers/joinJsx.js +1 -1
- package/dist/ui/components/ProgressBar/index.js +1 -1
- package/dist/ui/components/Prompt/Dialog.js +1 -1
- package/dist/ui/components/Prompt/Modal.js +2 -2
- package/dist/ui/components/RowOrColumn/index.js +2 -2
- package/dist/ui/components/Search/Base.js +5 -5
- package/dist/ui/components/Search/Dialog.js +2 -2
- package/dist/ui/components/Search/Inline.js +1 -1
- package/dist/ui/components/Search/Modal.js +3 -3
- package/dist/ui/components/Search/index.d.ts +2 -2
- package/dist/ui/components/Search/index.js +2 -2
- package/dist/ui/components/Sidebar/index.js +2 -2
- package/dist/ui/components/SparkLine/index.js +2 -2
- package/dist/ui/components/Table/index.js +2 -2
- package/dist/ui/components/TextEdit/CheckboxEdit.js +8 -8
- package/dist/ui/components/TextEdit/ColourEdit.js +6 -6
- package/dist/ui/components/TextEdit/LengthBox.js +1 -1
- package/dist/ui/components/TextEdit/ListboxEdit.js +5 -5
- package/dist/ui/components/TextEdit/RadioGroup.js +5 -5
- package/dist/ui/components/TextEdit/TextEdit.d.ts +1 -1
- package/dist/ui/components/TextEdit/TextEdit.js +14 -14
- package/dist/ui/components/TextEdit/common.js +2 -2
- package/dist/ui/components/TextWithButton/index.js +1 -1
- package/dist/ui/components/Toast/index.js +1 -1
- package/dist/ui/components/UserImage/index.js +3 -3
- package/dist/ui/helpers/axiosHelper.js +2 -2
- package/dist/ui/helpers/callOpenApi/cached.d.ts +2 -2
- package/dist/ui/helpers/callOpenApi/cached.js +3 -3
- package/dist/ui/helpers/callOpenApi/direct.d.ts +1 -1
- package/dist/ui/helpers/callOpenApi/direct.js +4 -4
- package/dist/ui/helpers/callOpenApi/hook.d.ts +2 -2
- package/dist/ui/helpers/callOpenApi/hook.js +1 -1
- package/dist/ui/helpers/callOpenApi/index.d.ts +1 -1
- package/dist/ui/helpers/callOpenApi/index.js +1 -1
- package/dist/ui/helpers/callOpenApi/types.d.ts +1 -1
- package/dist/ui/helpers/cookie/get.js +1 -1
- package/dist/ui/helpers/cookie/set.js +2 -2
- package/dist/ui/helpers/cookie/use.d.ts +1 -1
- package/dist/ui/helpers/cookie/use.js +1 -1
- package/dist/ui/helpers/date.js +1 -1
- package/dist/ui/helpers/routes.d.ts +1 -1
- package/dist/ui/helpers/routes.js +2 -2
- package/dist/ui/helpers/useLocalStorage.js +2 -2
- package/dist/ui/helpers/useOnClickOutside.js +1 -1
- package/dist/ui/helpers/useQueryString.js +2 -2
- package/dist/ui/helpers/useResize.js +1 -1
- package/dist/ui/icons/CrossIcon.js +1 -1
- package/dist/ui/styles/common.js +2 -2
- package/dist/ui/styles/standaloneStyles.js +1 -1
- package/package.json +4 -3
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { DYNAMOKEYS, IQueryDynamo, Key } from '../types';
|
|
2
1
|
import DynamoDB from 'aws-sdk/clients/dynamodb';
|
|
2
|
+
import { DYNAMOKEYS, IQueryDynamo, Key } from '../types';
|
|
3
3
|
export declare let dynamoDb: DynamoDB.DocumentClient;
|
|
4
4
|
export declare const setDynamo: (region: string) => void;
|
|
5
5
|
export declare const putDynamo: <T>(item: T, tableName: string) => Promise<{
|
|
@@ -33,11 +33,15 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
33
33
|
};
|
|
34
34
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
35
35
|
exports.getDynamoUpdates = exports.wipeTable = exports.getDynamoTtlMinutes = exports.getDynamoTtlDays = exports.queryDynamo = exports.getItemsDynamo = exports.getItemDynamo = exports.scan = exports.batchDelete = exports.batchWrite = exports.putDynamo = exports.setDynamo = exports.dynamoDb = void 0;
|
|
36
|
-
|
|
36
|
+
/* eslint-disable guard-for-in */
|
|
37
|
+
/* eslint-disable no-restricted-syntax */
|
|
38
|
+
/* eslint-disable no-await-in-loop */
|
|
39
|
+
/* eslint-disable prefer-const */
|
|
40
|
+
const dynamodb_1 = __importStar(require("aws-sdk/clients/dynamodb"));
|
|
37
41
|
const array_1 = require("../../common/helpers/array");
|
|
38
|
-
const sleep_1 = require("../../common/helpers/sleep");
|
|
39
42
|
const async_1 = require("../../common/helpers/async");
|
|
40
|
-
const
|
|
43
|
+
const log_1 = require("../../common/helpers/log");
|
|
44
|
+
const sleep_1 = require("../../common/helpers/sleep");
|
|
41
45
|
// eslint-disable-next-line import/no-mutable-exports
|
|
42
46
|
exports.dynamoDb = new dynamodb_1.DocumentClient();
|
|
43
47
|
const setDynamo = (region) => {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
+
import { aws_dynamodb as dynamodb, Stack } from 'aws-cdk-lib';
|
|
1
2
|
import { IGeneratedDynamoData } from '../types';
|
|
2
|
-
import { Stack, aws_dynamodb as dynamodb } from 'aws-cdk-lib';
|
|
3
3
|
export declare const generateTableRef: ({ stack, baseKey, hasStream, hasGSI, }: {
|
|
4
4
|
hasStream: boolean;
|
|
5
5
|
hasGSI: boolean;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { ILambdaConfigs } from '../types';
|
|
2
|
-
import { Construct } from 'constructs';
|
|
3
1
|
import { aws_certificatemanager as certmgr, aws_route53 as route53 } from 'aws-cdk-lib';
|
|
4
2
|
import { TokenAuthorizer } from 'aws-cdk-lib/aws-apigateway/lib/authorizers/lambda';
|
|
3
|
+
import { Construct } from 'constructs';
|
|
4
|
+
import { ILambdaConfigs } from '../types';
|
|
5
5
|
export declare const openApiImpl: (p: {
|
|
6
6
|
stack: Construct;
|
|
7
7
|
/**
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.openApiImpl = void 0;
|
|
4
4
|
/* eslint-disable no-new */
|
|
5
|
+
const aws_cdk_lib_1 = require("aws-cdk-lib");
|
|
5
6
|
const array_1 = require("../../common/helpers/array");
|
|
6
7
|
const log_1 = require("../../common/helpers/log");
|
|
7
|
-
const aws_cdk_lib_1 = require("aws-cdk-lib");
|
|
8
8
|
// eslint-disable-next-line
|
|
9
9
|
const getPaths = (schema) => Object.entries(schema.paths).map(([fullPath, verbs]) => ({
|
|
10
10
|
fullPath,
|
package/dist/api/helpers/s3.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
|
-
import { Blob } from 'aws-sdk/lib/dynamodb/document_client';
|
|
3
2
|
import S3 from 'aws-sdk/clients/s3';
|
|
4
|
-
import { PromiseResult } from 'aws-sdk/lib/request';
|
|
5
3
|
import { AWSError } from 'aws-sdk/lib/core';
|
|
4
|
+
import { Blob } from 'aws-sdk/lib/dynamodb/document_client';
|
|
5
|
+
import { PromiseResult } from 'aws-sdk/lib/request';
|
|
6
6
|
import { error } from '../../common/helpers/log';
|
|
7
7
|
export declare const setS3: (region: string) => void;
|
|
8
8
|
export declare const getS3Object: ({ fileurl, }: {
|
package/dist/api/helpers/s3.js
CHANGED
|
@@ -26,8 +26,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
26
26
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
27
27
|
exports.getPresignedPostURL = exports.listFiles = exports.copyFile = exports.deleteFiles = exports.deleteFile = exports.uploadFile = exports.putS3Object = exports.getS3Objects = exports.getS3Object = exports.setS3 = void 0;
|
|
28
28
|
const s3_1 = __importDefault(require("aws-sdk/clients/s3"));
|
|
29
|
-
const log_1 = require("../../common/helpers/log");
|
|
30
29
|
const array_1 = require("../../common/helpers/array");
|
|
30
|
+
const log_1 = require("../../common/helpers/log");
|
|
31
31
|
let s3 = new s3_1.default();
|
|
32
32
|
const setS3 = (region) => {
|
|
33
33
|
s3 = new s3_1.default({ region });
|
package/dist/api/helpers/sqs.js
CHANGED
|
@@ -13,8 +13,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
13
13
|
};
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
15
|
exports.sendMessages = exports.setSqs = exports.sqs = void 0;
|
|
16
|
-
const common_1 = require("../../common");
|
|
17
16
|
const sqs_1 = __importDefault(require("aws-sdk/clients/sqs"));
|
|
17
|
+
const common_1 = require("../../common");
|
|
18
18
|
// eslint-disable-next-line import/no-mutable-exports
|
|
19
19
|
exports.sqs = new sqs_1.default();
|
|
20
20
|
const setSqs = (region) => {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { TGetAndValidateToken } from './validations';
|
|
2
|
-
import { User } from '../../ui/helpers/jwt';
|
|
3
1
|
import { TLang } from '../../common/helpers/i18n';
|
|
2
|
+
import { User } from '../../ui/helpers/jwt';
|
|
4
3
|
import { APIGatewayEvent, APIGatewayProxyResult } from '../types';
|
|
4
|
+
import { TGetAndValidateToken } from './validations';
|
|
5
5
|
export type NextType<T> = ({ event, body, params, userProfile, lang, }: {
|
|
6
6
|
params: Record<string, string>;
|
|
7
7
|
event: APIGatewayEvent;
|
|
@@ -14,12 +14,12 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
15
|
exports.validateOpenApi = void 0;
|
|
16
16
|
// eslint-disable-next-line import/no-unresolved
|
|
17
|
-
const
|
|
18
|
-
const
|
|
17
|
+
const openapi_request_validator_1 = __importDefault(require("openapi-request-validator"));
|
|
18
|
+
const i18n_1 = require("../../common/helpers/i18n");
|
|
19
19
|
const log_1 = require("../../common/helpers/log");
|
|
20
20
|
const object_1 = require("../../common/helpers/object");
|
|
21
|
-
const
|
|
22
|
-
const
|
|
21
|
+
const api_1 = require("./api");
|
|
22
|
+
const validations_1 = require("./validations");
|
|
23
23
|
//
|
|
24
24
|
const getOperation = ({ path, method, resource, schema, }) => {
|
|
25
25
|
var _a;
|
|
@@ -14,10 +14,10 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
15
|
exports.getAndValidateToken = void 0;
|
|
16
16
|
/* eslint-disable import/no-unresolved */
|
|
17
|
-
const api_1 = require("./api");
|
|
18
|
-
const log_1 = require("../../common/helpers/log");
|
|
19
17
|
const jsonwebtoken_1 = require("jsonwebtoken");
|
|
20
18
|
const jwks_rsa_1 = __importDefault(require("jwks-rsa"));
|
|
19
|
+
const log_1 = require("../../common/helpers/log");
|
|
20
|
+
const api_1 = require("./api");
|
|
21
21
|
let jwksClient;
|
|
22
22
|
const jwtVerify = ({ token, jwksUri, issuer, }) => __awaiter(void 0, void 0, void 0, function* () {
|
|
23
23
|
return new Promise((resolve, reject) => {
|
package/dist/api/index.d.ts
CHANGED
package/dist/api/index.js
CHANGED
|
@@ -14,5 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./types"), exports);
|
|
18
17
|
__exportStar(require("./helpers"), exports);
|
|
18
|
+
__exportStar(require("./types"), exports);
|
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -14,6 +14,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./ui"), exports);
|
|
18
|
-
__exportStar(require("./common"), exports);
|
|
19
17
|
__exportStar(require("./api"), exports);
|
|
18
|
+
__exportStar(require("./common"), exports);
|
|
19
|
+
__exportStar(require("./ui"), exports);
|
|
@@ -4,12 +4,12 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.BorderGradient = void 0;
|
|
7
|
-
const
|
|
8
|
-
const object_1 = require("../../../common/helpers/object");
|
|
7
|
+
const react_1 = require("@emotion/react");
|
|
9
8
|
const styled_1 = __importDefault(require("@emotion/styled"));
|
|
10
|
-
const
|
|
11
|
-
const
|
|
12
|
-
const
|
|
9
|
+
const react_2 = __importDefault(require("react"));
|
|
10
|
+
const object_1 = require("../../../common/helpers/object");
|
|
11
|
+
const colours_1 = require("../../styles/colours");
|
|
12
|
+
const BGcss = (0, react_1.css) `
|
|
13
13
|
display: flex;
|
|
14
14
|
border: 0;
|
|
15
15
|
padding: 3px;
|
|
@@ -63,12 +63,12 @@ const BorderGradient = ({ left = colours_1.colours.orange, right = colours_1.col
|
|
|
63
63
|
style,
|
|
64
64
|
'data-ccnd': CCND,
|
|
65
65
|
};
|
|
66
|
-
const child = (
|
|
67
|
-
!fill &&
|
|
68
|
-
fill &&
|
|
66
|
+
const child = (react_2.default.createElement(react_2.default.Fragment, null,
|
|
67
|
+
!fill && react_2.default.createElement(Padding, { style: { padding } }, children),
|
|
68
|
+
fill && react_2.default.createElement(FeatureBoxFill, { style: { padding } }, children)));
|
|
69
69
|
if (href) {
|
|
70
|
-
return
|
|
70
|
+
return react_2.default.createElement(BGALink, Object.assign({}, props), child);
|
|
71
71
|
}
|
|
72
|
-
return
|
|
72
|
+
return react_2.default.createElement(BGLink, Object.assign({}, props), child);
|
|
73
73
|
};
|
|
74
74
|
exports.BorderGradient = BorderGradient;
|
|
@@ -5,11 +5,11 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.Button = exports.ButtonBase = void 0;
|
|
7
7
|
/* eslint-disable react/destructuring-assignment */
|
|
8
|
-
const
|
|
9
|
-
const react_1 = __importDefault(require("react"));
|
|
8
|
+
const react_1 = require("@emotion/react");
|
|
10
9
|
const styled_1 = __importDefault(require("@emotion/styled"));
|
|
11
|
-
const react_2 = require("
|
|
12
|
-
|
|
10
|
+
const react_2 = __importDefault(require("react"));
|
|
11
|
+
const colours_1 = require("../../styles/colours");
|
|
12
|
+
exports.ButtonBase = (0, react_1.css) `
|
|
13
13
|
text-decoration: none;
|
|
14
14
|
display: flex;
|
|
15
15
|
justify-content: center;
|
|
@@ -65,6 +65,6 @@ const Button = (props) => {
|
|
|
65
65
|
? // eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
66
66
|
BaseA
|
|
67
67
|
: BaseButton;
|
|
68
|
-
return (
|
|
68
|
+
return (react_2.default.createElement(Component, Object.assign({ className: props.className, "data-invert": props.invert, "data-disabled": (_a = props.disabled) !== null && _a !== void 0 ? _a : false, role: "button", title: props.title || undefined, "data-theme": props.colourTheme || 'green' }, props), props.children));
|
|
69
69
|
};
|
|
70
70
|
exports.Button = Button;
|
|
@@ -4,10 +4,10 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.Chevron = void 0;
|
|
7
|
-
const Icon_1 = require("../Icon");
|
|
8
7
|
const styled_1 = __importDefault(require("@emotion/styled"));
|
|
9
8
|
const react_1 = __importDefault(require("react"));
|
|
10
9
|
const ChevronRight_1 = require("../../icons/ChevronRight");
|
|
10
|
+
const Icon_1 = require("../Icon");
|
|
11
11
|
const Base = styled_1.default.span `
|
|
12
12
|
font-size: 2rem;
|
|
13
13
|
display: flex;
|
|
@@ -4,9 +4,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.Close = void 0;
|
|
7
|
-
const dom_1 = require("../../helpers/dom");
|
|
8
7
|
const styled_1 = __importDefault(require("@emotion/styled"));
|
|
9
8
|
const react_1 = __importDefault(require("react"));
|
|
9
|
+
const dom_1 = require("../../helpers/dom");
|
|
10
10
|
const Base = styled_1.default.div `
|
|
11
11
|
position: absolute;
|
|
12
12
|
z-index: 1;
|
|
@@ -13,10 +13,10 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
13
13
|
};
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
15
|
exports.ConfirmDialog = void 0;
|
|
16
|
-
const Modal_1 = require("./Modal");
|
|
17
|
-
const log_1 = require("../../../common/helpers/log");
|
|
18
16
|
const react_1 = __importDefault(require("react"));
|
|
19
17
|
const client_1 = require("react-dom/client");
|
|
18
|
+
const log_1 = require("../../../common/helpers/log");
|
|
19
|
+
const Modal_1 = require("./Modal");
|
|
20
20
|
/**
|
|
21
21
|
* opens a dialog programatically
|
|
22
22
|
* @param param0
|
|
@@ -4,12 +4,12 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.ConfirmModal = void 0;
|
|
7
|
+
const styled_1 = __importDefault(require("@emotion/styled"));
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
7
9
|
const Button_1 = require("../Button");
|
|
8
10
|
const FlexColumn_1 = require("../FlexColumn");
|
|
9
11
|
const FlexRow_1 = require("../FlexRow");
|
|
10
12
|
const Modal_1 = require("../Modal/Modal");
|
|
11
|
-
const styled_1 = __importDefault(require("@emotion/styled"));
|
|
12
|
-
const react_1 = __importDefault(require("react"));
|
|
13
13
|
const Base = styled_1.default.div `
|
|
14
14
|
width: 95vw;
|
|
15
15
|
max-width: 30rem;
|
|
@@ -14,6 +14,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./types"), exports);
|
|
18
17
|
__exportStar(require("./Dialog"), exports);
|
|
19
18
|
__exportStar(require("./Modal"), exports);
|
|
19
|
+
__exportStar(require("./types"), exports);
|
|
@@ -27,13 +27,13 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
27
27
|
};
|
|
28
28
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
29
|
exports.DropdownList = void 0;
|
|
30
|
+
const styled_1 = __importDefault(require("@emotion/styled"));
|
|
31
|
+
const react_1 = __importStar(require("react"));
|
|
30
32
|
const dom_1 = require("../../helpers/dom");
|
|
31
|
-
const common_1 = require("../../styles/common");
|
|
32
33
|
const useOnClickOutside_1 = require("../../helpers/useOnClickOutside");
|
|
33
34
|
const colours_1 = require("../../styles/colours");
|
|
35
|
+
const common_1 = require("../../styles/common");
|
|
34
36
|
const KebabDots_1 = require("../KebabDots");
|
|
35
|
-
const styled_1 = __importDefault(require("@emotion/styled"));
|
|
36
|
-
const react_1 = __importStar(require("react"));
|
|
37
37
|
const Base = styled_1.default.div `
|
|
38
38
|
display: flex;
|
|
39
39
|
flex-flow: row;
|
|
@@ -13,9 +13,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
13
13
|
};
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
15
|
exports.DropdownListDialog = void 0;
|
|
16
|
-
const index_1 = require("./index");
|
|
17
16
|
const react_1 = __importDefault(require("react"));
|
|
18
17
|
const client_1 = require("react-dom/client");
|
|
18
|
+
const index_1 = require("./index");
|
|
19
19
|
const DropdownListDialog = (p) => __awaiter(void 0, void 0, void 0, function* () {
|
|
20
20
|
return new Promise((res) => {
|
|
21
21
|
const id = 'ag-common-ddld';
|
|
@@ -4,8 +4,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.FlexColumn = void 0;
|
|
7
|
-
const react_1 = __importDefault(require("react"));
|
|
8
7
|
const styled_1 = __importDefault(require("@emotion/styled"));
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
9
|
const Base = styled_1.default.div `
|
|
10
10
|
position: relative;
|
|
11
11
|
display: flex;
|
|
@@ -4,8 +4,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.FlexRow = void 0;
|
|
7
|
-
const react_1 = __importDefault(require("react"));
|
|
8
7
|
const styled_1 = __importDefault(require("@emotion/styled"));
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
9
|
const Base = styled_1.default.div `
|
|
10
10
|
position: relative;
|
|
11
11
|
overflow: hidden;
|
|
@@ -4,10 +4,10 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.Icon = exports.IconF = void 0;
|
|
7
|
-
const common_1 = require("../../styles/common");
|
|
8
|
-
const object_1 = require("../../../common/helpers/object");
|
|
9
|
-
const react_1 = __importDefault(require("react"));
|
|
10
7
|
const styled_1 = __importDefault(require("@emotion/styled"));
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
|
+
const object_1 = require("../../../common/helpers/object");
|
|
10
|
+
const common_1 = require("../../styles/common");
|
|
11
11
|
exports.IconF = styled_1.default.span `
|
|
12
12
|
transition: all 200ms;
|
|
13
13
|
display: flex;
|
|
@@ -15,8 +15,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
exports.Image = void 0;
|
|
18
|
-
const react_1 = __importDefault(require("react"));
|
|
19
18
|
const styled_1 = __importDefault(require("@emotion/styled"));
|
|
19
|
+
const react_1 = __importDefault(require("react"));
|
|
20
20
|
const media_1 = require("../../styles/media");
|
|
21
21
|
const Base = styled_1.default.img `
|
|
22
22
|
object-fit: contain;
|
|
@@ -4,10 +4,10 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.KebabDots = void 0;
|
|
7
|
-
const Icon_1 = require("../Icon");
|
|
8
|
-
const react_1 = __importDefault(require("react"));
|
|
9
7
|
const styled_1 = __importDefault(require("@emotion/styled"));
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
10
9
|
const HorizontalDots_1 = require("../../icons/HorizontalDots");
|
|
10
|
+
const Icon_1 = require("../Icon");
|
|
11
11
|
const IconStyled = (0, styled_1.default)(Icon_1.Icon) `
|
|
12
12
|
position: absolute;
|
|
13
13
|
`;
|
|
@@ -13,9 +13,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
13
13
|
};
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
15
|
exports.ModalDialog = void 0;
|
|
16
|
-
const Modal_1 = require("./Modal");
|
|
17
16
|
const react_1 = __importDefault(require("react"));
|
|
18
17
|
const client_1 = require("react-dom/client");
|
|
18
|
+
const Modal_1 = require("./Modal");
|
|
19
19
|
const ModalDialog = (content) => __awaiter(void 0, void 0, void 0, function* () {
|
|
20
20
|
return new Promise((res) => {
|
|
21
21
|
const wrapper = document.body.appendChild(document.createElement('div'));
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { IModal } from './types';
|
|
2
1
|
import React from 'react';
|
|
2
|
+
import { IModal } from './types';
|
|
3
3
|
export declare const ModalItem: import("@emotion/styled").StyledComponent<{
|
|
4
4
|
theme?: import("@emotion/react").Theme | undefined;
|
|
5
5
|
as?: React.ElementType<any> | undefined;
|
|
@@ -27,11 +27,11 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
27
27
|
};
|
|
28
28
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
29
|
exports.Modal = exports.ModalItem = void 0;
|
|
30
|
-
const
|
|
30
|
+
const styled_1 = __importDefault(require("@emotion/styled"));
|
|
31
|
+
const react_1 = __importStar(require("react"));
|
|
31
32
|
const useOnClickOutside_1 = require("../../helpers/useOnClickOutside");
|
|
32
33
|
const styles_1 = require("../../styles");
|
|
33
|
-
const
|
|
34
|
-
const styled_1 = __importDefault(require("@emotion/styled"));
|
|
34
|
+
const Close_1 = require("../Close");
|
|
35
35
|
const FixedBackground = styled_1.default.div `
|
|
36
36
|
position: fixed;
|
|
37
37
|
top: 0;
|
|
@@ -14,6 +14,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./types"), exports);
|
|
18
|
-
__exportStar(require("./Modal"), exports);
|
|
19
17
|
__exportStar(require("./Dialog"), exports);
|
|
18
|
+
__exportStar(require("./Modal"), exports);
|
|
19
|
+
__exportStar(require("./types"), exports);
|
|
@@ -4,12 +4,12 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.OpenApiCodeBlock = void 0;
|
|
7
|
-
const
|
|
7
|
+
const styled_1 = __importDefault(require("@emotion/styled"));
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
|
+
const FlexRow_1 = require("../FlexRow");
|
|
8
10
|
const curl_1 = require("./curl");
|
|
9
11
|
const fetch_1 = require("./fetch");
|
|
10
|
-
const
|
|
11
|
-
const react_1 = __importDefault(require("react"));
|
|
12
|
-
const styled_1 = __importDefault(require("@emotion/styled"));
|
|
12
|
+
const common_1 = require("./helpers/common");
|
|
13
13
|
const Base = styled_1.default.div `
|
|
14
14
|
display: flex;
|
|
15
15
|
flex-flow: column;
|
|
@@ -4,8 +4,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.getBody = void 0;
|
|
7
|
-
const common_1 = require("../../helpers/common");
|
|
8
7
|
const react_1 = __importDefault(require("react"));
|
|
8
|
+
const common_1 = require("../../helpers/common");
|
|
9
9
|
const getBody = (p) => {
|
|
10
10
|
const { nice } = (0, common_1.getBodyJson)(p) || {};
|
|
11
11
|
if (!nice) {
|
|
@@ -4,9 +4,9 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.getSecurityLine = void 0;
|
|
7
|
+
const react_1 = __importDefault(require("react"));
|
|
7
8
|
const string_1 = require("../../../../../common/helpers/string");
|
|
8
9
|
const common_1 = require("../../helpers/common");
|
|
9
|
-
const react_1 = __importDefault(require("react"));
|
|
10
10
|
const getSecurityLine = (p, { operation }) => {
|
|
11
11
|
const sec = (0, common_1.getSecurity)(p, { operation });
|
|
12
12
|
if (sec === null) {
|
|
@@ -4,12 +4,12 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.Curl = void 0;
|
|
7
|
-
const getCurlLines_1 = require("./helpers/getCurlLines");
|
|
8
|
-
const common_1 = require("../helpers/common");
|
|
9
|
-
const common_2 = require("../../../../common");
|
|
10
|
-
const joinJsx_1 = require("../helpers/joinJsx");
|
|
11
|
-
const react_1 = __importDefault(require("react"));
|
|
12
7
|
const styled_1 = __importDefault(require("@emotion/styled"));
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
|
+
const common_1 = require("../../../../common");
|
|
10
|
+
const common_2 = require("../helpers/common");
|
|
11
|
+
const joinJsx_1 = require("../helpers/joinJsx");
|
|
12
|
+
const getCurlLines_1 = require("./helpers/getCurlLines");
|
|
13
13
|
const Base = styled_1.default.div `
|
|
14
14
|
white-space: pre;
|
|
15
15
|
`;
|
|
@@ -22,13 +22,13 @@ const Curl = ({ ops, p, }) => {
|
|
|
22
22
|
verb.toUpperCase()),
|
|
23
23
|
react_1.default.createElement(react_1.default.Fragment, null,
|
|
24
24
|
"--url ",
|
|
25
|
-
react_1.default.createElement(
|
|
25
|
+
react_1.default.createElement(common_2.Highlight, null,
|
|
26
26
|
"'",
|
|
27
27
|
fullApiUrl,
|
|
28
28
|
"'")),
|
|
29
29
|
...(headerLines || []),
|
|
30
30
|
bodyLine,
|
|
31
|
-
].filter(
|
|
31
|
+
].filter(common_1.notEmpty);
|
|
32
32
|
return react_1.default.createElement(Base, null, (0, joinJsx_1.joinJsxWithSlash)(rows));
|
|
33
33
|
};
|
|
34
34
|
exports.Curl = Curl;
|
|
@@ -4,8 +4,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.getFetchCall = void 0;
|
|
7
|
-
const common_1 = require("../../helpers/common");
|
|
8
7
|
const react_1 = __importDefault(require("react"));
|
|
8
|
+
const common_1 = require("../../helpers/common");
|
|
9
9
|
const getFetchCall = (p, ops) => {
|
|
10
10
|
return (react_1.default.createElement(react_1.default.Fragment, null,
|
|
11
11
|
react_1.default.createElement(common_1.Highlight, null, "const"),
|
|
@@ -4,39 +4,39 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.getRequestOptions = void 0;
|
|
7
|
-
const common_1 = require("../../helpers/common");
|
|
8
|
-
const joinJsx_1 = require("../../helpers/joinJsx");
|
|
9
|
-
const common_2 = require("../../../../../common");
|
|
10
|
-
const react_1 = __importDefault(require("react"));
|
|
11
7
|
const styled_1 = __importDefault(require("@emotion/styled"));
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
|
+
const common_1 = require("../../../../../common");
|
|
10
|
+
const common_2 = require("../../helpers/common");
|
|
11
|
+
const joinJsx_1 = require("../../helpers/joinJsx");
|
|
12
12
|
const rb = react_1.default.createElement(react_1.default.Fragment, null, "}");
|
|
13
13
|
const lb = react_1.default.createElement(react_1.default.Fragment, null, "{");
|
|
14
14
|
const Lpad = styled_1.default.div `
|
|
15
15
|
padding-left: 0.5rem;
|
|
16
16
|
`;
|
|
17
17
|
const getRequestOptions = (p, ops) => {
|
|
18
|
-
const { nice } = (0,
|
|
18
|
+
const { nice } = (0, common_2.getBodyJson)(p) || {};
|
|
19
19
|
if (!nice) {
|
|
20
20
|
return undefined;
|
|
21
21
|
}
|
|
22
|
-
const sec = (0,
|
|
22
|
+
const sec = (0, common_2.getSecurity)(p, ops);
|
|
23
23
|
const h1 = (react_1.default.createElement(react_1.default.Fragment, null,
|
|
24
24
|
' ',
|
|
25
|
-
react_1.default.createElement(
|
|
25
|
+
react_1.default.createElement(common_2.Highlight, null, "'Content-Type'"),
|
|
26
26
|
":",
|
|
27
27
|
' ',
|
|
28
|
-
react_1.default.createElement(
|
|
28
|
+
react_1.default.createElement(common_2.Highlight, null, "'application/json'")));
|
|
29
29
|
let h2;
|
|
30
30
|
if (sec) {
|
|
31
31
|
h2 = (react_1.default.createElement(react_1.default.Fragment, null,
|
|
32
32
|
' ',
|
|
33
|
-
react_1.default.createElement(
|
|
33
|
+
react_1.default.createElement(common_2.Highlight, null,
|
|
34
34
|
"'",
|
|
35
|
-
(0,
|
|
35
|
+
(0, common_1.toTitleCase)(sec.name),
|
|
36
36
|
"'"),
|
|
37
37
|
":",
|
|
38
38
|
' ',
|
|
39
|
-
react_1.default.createElement(
|
|
39
|
+
react_1.default.createElement(common_2.Highlight, null,
|
|
40
40
|
"'",
|
|
41
41
|
p.apiKey || '(API KEY)',
|
|
42
42
|
"'")));
|
|
@@ -49,9 +49,9 @@ const getRequestOptions = (p, ops) => {
|
|
|
49
49
|
","));
|
|
50
50
|
const body = (react_1.default.createElement(react_1.default.Fragment, null,
|
|
51
51
|
"body: ",
|
|
52
|
-
react_1.default.createElement(
|
|
52
|
+
react_1.default.createElement(common_2.Highlight2, null, "JSON"),
|
|
53
53
|
".",
|
|
54
|
-
react_1.default.createElement(
|
|
54
|
+
react_1.default.createElement(common_2.Highlight, null, "stringify"),
|
|
55
55
|
"(",
|
|
56
56
|
nice,
|
|
57
57
|
")"));
|
|
@@ -60,7 +60,7 @@ const getRequestOptions = (p, ops) => {
|
|
|
60
60
|
lb,
|
|
61
61
|
react_1.default.createElement(Lpad, null,
|
|
62
62
|
"method: ",
|
|
63
|
-
react_1.default.createElement(
|
|
63
|
+
react_1.default.createElement(common_2.Highlight, null,
|
|
64
64
|
"'",
|
|
65
65
|
ops.verb.toUpperCase(),
|
|
66
66
|
"'"),
|