@apicurio/common-ui-components 2.0.0 → 2.0.2
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/auth/ApplicationAuth.d.ts +4 -3
- package/dist/auth/AuthConfigContext.d.ts +2 -2
- package/dist/auth/IfAuth.d.ts +2 -1
- package/dist/auth/index.d.ts +4 -4
- package/dist/auth/useAuth.d.ts +8 -2
- package/dist/common/DateTime.d.ts +2 -1
- package/dist/common/FromNow.d.ts +2 -1
- package/dist/common/If.d.ts +2 -1
- package/dist/common/IfNotEmpty.d.ts +2 -1
- package/dist/common/IfNotLoading.d.ts +2 -1
- package/dist/common/ListWithToolbar.d.ts +2 -1
- package/dist/common/ObjectDropdown.d.ts +3 -2
- package/dist/common/ObjectSelect.d.ts +3 -1
- package/dist/common/ToggleIcon.d.ts +2 -1
- package/dist/common/UrlUpload.d.ts +2 -1
- package/dist/common/index.d.ts +10 -10
- package/dist/main.d.ts +4 -4
- package/dist/main.js +657 -541
- package/dist/modals/AppAboutModal.d.ts +2 -1
- package/dist/modals/BasicAuthModal.d.ts +13 -0
- package/dist/modals/PleaseWaitModal.d.ts +2 -1
- package/dist/modals/ProgressModal.d.ts +2 -1
- package/dist/modals/index.d.ts +4 -3
- package/dist/table/ChipFilter/ChipFilter.d.ts +3 -2
- package/dist/table/ChipFilter/components/FilterCheckbox.d.ts +2 -1
- package/dist/table/ChipFilter/components/FilterSearch.d.ts +3 -2
- package/dist/table/ChipFilter/components/index.d.ts +3 -3
- package/dist/table/ChipFilter/index.d.ts +5 -5
- package/dist/table/Pagination.d.ts +2 -1
- package/dist/table/ResponsiveTable.d.ts +6 -6
- package/dist/table/TableSkeleton.d.ts +2 -1
- package/dist/table/index.d.ts +5 -5
- package/package.json +17 -17
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import React,
|
|
1
|
+
import { default as React, FunctionComponent } from 'react';
|
|
2
|
+
|
|
2
3
|
/**
|
|
3
4
|
* Properties
|
|
4
5
|
*/
|
|
5
|
-
export type
|
|
6
|
+
export type AuthProps = {
|
|
6
7
|
children: React.ReactNode;
|
|
7
8
|
};
|
|
8
9
|
/**
|
|
9
10
|
* Protect the application with OIDC authentication.
|
|
10
11
|
*/
|
|
11
|
-
export declare const ApplicationAuth: FunctionComponent<
|
|
12
|
+
export declare const ApplicationAuth: FunctionComponent<AuthProps>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
export interface AuthConfig {
|
|
3
|
-
type: "none" | "oidc";
|
|
3
|
+
type: "none" | "basic" | "oidc";
|
|
4
4
|
options?: any;
|
|
5
5
|
}
|
|
6
|
-
export declare const AuthConfigContext: import(
|
|
6
|
+
export declare const AuthConfigContext: import('react').Context<AuthConfig>;
|
package/dist/auth/IfAuth.d.ts
CHANGED
package/dist/auth/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export * from
|
|
2
|
-
export * from
|
|
3
|
-
export * from
|
|
4
|
-
export * from
|
|
1
|
+
export * from './AuthConfigContext';
|
|
2
|
+
export * from './ApplicationAuth';
|
|
3
|
+
export * from './IfAuth';
|
|
4
|
+
export * from './useAuth';
|
package/dist/auth/useAuth.d.ts
CHANGED
|
@@ -1,12 +1,18 @@
|
|
|
1
1
|
/** ********************************
|
|
2
2
|
* AuthService interface and hook.
|
|
3
3
|
** ******************************** */
|
|
4
|
+
export interface UsernameAndPassword {
|
|
5
|
+
username: string;
|
|
6
|
+
password: string;
|
|
7
|
+
}
|
|
4
8
|
export interface AuthService {
|
|
5
|
-
|
|
9
|
+
isOidcAuthEnabled: () => boolean;
|
|
10
|
+
isBasicAuthEnabled: () => boolean;
|
|
6
11
|
isAuthenticated: () => Promise<boolean>;
|
|
7
12
|
getUsername: () => Promise<string | undefined>;
|
|
8
13
|
getToken: () => Promise<string | undefined>;
|
|
9
|
-
|
|
14
|
+
getUsernameAndPassword: () => UsernameAndPassword | undefined;
|
|
15
|
+
login: (username: string, password: string) => Promise<void>;
|
|
10
16
|
logout: () => Promise<void>;
|
|
11
17
|
}
|
|
12
18
|
/**
|
package/dist/common/FromNow.d.ts
CHANGED
package/dist/common/If.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { FunctionComponent } from
|
|
1
|
+
import { FunctionComponent } from 'react';
|
|
2
|
+
|
|
2
3
|
/**
|
|
3
4
|
* Properties
|
|
4
5
|
*/
|
|
@@ -13,6 +14,7 @@ export type ObjectSelectProps = {
|
|
|
13
14
|
toggleId?: string;
|
|
14
15
|
toggleClassname?: string;
|
|
15
16
|
testId?: string;
|
|
17
|
+
appendTo?: "inline" | "document";
|
|
16
18
|
};
|
|
17
19
|
/**
|
|
18
20
|
* A generic control that makes it easier to create a <Select> from an array of objects.
|
package/dist/common/index.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
export * from
|
|
2
|
-
export * from
|
|
3
|
-
export * from
|
|
4
|
-
export * from
|
|
5
|
-
export * from
|
|
6
|
-
export * from
|
|
7
|
-
export * from
|
|
8
|
-
export * from
|
|
9
|
-
export * from
|
|
10
|
-
export * from
|
|
1
|
+
export * from './DateTime';
|
|
2
|
+
export * from './FromNow';
|
|
3
|
+
export * from './If';
|
|
4
|
+
export * from './IfNotEmpty';
|
|
5
|
+
export * from './IfNotLoading';
|
|
6
|
+
export * from './ListWithToolbar';
|
|
7
|
+
export * from './ObjectDropdown';
|
|
8
|
+
export * from './ObjectSelect';
|
|
9
|
+
export * from './ToggleIcon';
|
|
10
|
+
export * from './UrlUpload';
|
package/dist/main.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export * from
|
|
2
|
-
export * from
|
|
3
|
-
export * from
|
|
4
|
-
export * from
|
|
1
|
+
export * from './auth';
|
|
2
|
+
export * from './common';
|
|
3
|
+
export * from './modals';
|
|
4
|
+
export * from './table';
|