serene-core-client 0.1.5 → 0.1.6
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/src/components/account/profile.d.ts +1 -1
- package/dist/src/components/account/profile.js +2 -2
- package/dist/src/components/basics/copy-text-icon.d.ts +1 -1
- package/dist/src/components/basics/copy-text-icon.js +1 -1
- package/dist/src/components/basics/editable-string-list.d.ts +1 -1
- package/dist/src/components/basics/editable-string-list.js +1 -1
- package/dist/src/components/basics/text-area-field.d.ts +1 -1
- package/dist/src/components/basics/text-area-field.js +1 -1
- package/dist/src/components/basics/view-link-field.d.ts +1 -1
- package/dist/src/components/basics/view-link-field.js +1 -1
- package/dist/src/components/basics/view-markdown-field.d.ts +1 -1
- package/dist/src/components/basics/view-markdown-field.js +1 -1
- package/dist/src/components/basics/view-text-field.d.ts +1 -1
- package/dist/src/components/basics/view-text-field.js +1 -1
- package/dist/src/components/buttons/labeled-icon-button.d.ts +1 -1
- package/dist/src/components/buttons/labeled-icon-button.js +1 -1
- package/dist/src/components/mailing-lists/sign-up.d.ts +1 -1
- package/dist/src/components/mailing-lists/sign-up.js +1 -1
- package/dist/src/components/notifications/action.d.ts +1 -1
- package/dist/src/components/notifications/action.js +1 -1
- package/dist/src/components/tech/load-techs.d.ts +1 -1
- package/dist/src/components/tech/load-techs.js +1 -1
- package/dist/src/components/tech/tech-autocomplete.d.ts +1 -1
- package/dist/src/components/tech/tech-autocomplete.js +1 -1
- package/dist/src/components/tips/load-tips.d.ts +1 -1
- package/dist/src/components/tips/load-tips.js +1 -1
- package/dist/src/components/tips/tip.d.ts +1 -1
- package/dist/src/components/tips/tip.js +1 -1
- package/package.json +1 -1
- package/src/components/account/profile.tsx +1 -1
|
@@ -4,5 +4,5 @@ interface Props {
|
|
|
4
4
|
serverUrl: string;
|
|
5
5
|
session: any;
|
|
6
6
|
}
|
|
7
|
-
export
|
|
7
|
+
export declare function Profile({ userProfile, clientUrl, serverUrl, session }: Props): import("react/jsx-runtime").JSX.Element;
|
|
8
8
|
export {};
|
|
@@ -5,13 +5,13 @@ import Button from '@mui/material/Button';
|
|
|
5
5
|
import TextField from '@mui/material/TextField';
|
|
6
6
|
import Select from '@mui/material/Select';
|
|
7
7
|
import { useEffect, useState } from 'react';
|
|
8
|
-
import ActionNotification from '../notifications/action';
|
|
8
|
+
import { ActionNotification } from '../notifications/action';
|
|
9
9
|
import { RestApiService } from '../../services/rest-api/service';
|
|
10
10
|
import { FormControl, InputLabel, Typography } from '@mui/material';
|
|
11
11
|
import { countries } from '../../services/locale/countries';
|
|
12
12
|
import { getUserPreferencesQuery } from '../../apollo/user-preferences';
|
|
13
13
|
import { ProfileService } from '../../services/users/profile-service';
|
|
14
|
-
export
|
|
14
|
+
export function Profile({ userProfile, clientUrl, serverUrl, session }) {
|
|
15
15
|
// Consts
|
|
16
16
|
const personalDetails = 'personal details';
|
|
17
17
|
// State
|
|
@@ -3,5 +3,5 @@ interface Props {
|
|
|
3
3
|
title?: string;
|
|
4
4
|
style?: any;
|
|
5
5
|
}
|
|
6
|
-
export
|
|
6
|
+
export declare function CopyTextIcon({ text, title, style }: Props): import("react/jsx-runtime").JSX.Element;
|
|
7
7
|
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import ContentCopyIcon from '@mui/icons-material/ContentCopy';
|
|
3
3
|
import { IconButton, Tooltip } from '@mui/material';
|
|
4
|
-
export
|
|
4
|
+
export function CopyTextIcon({ text, title = 'Copy', style = {} }) {
|
|
5
5
|
const handleCopy = async () => {
|
|
6
6
|
try {
|
|
7
7
|
await navigator.clipboard.writeText(text);
|
|
@@ -4,4 +4,4 @@ export interface Props {
|
|
|
4
4
|
setValues?: any;
|
|
5
5
|
onChange?: any;
|
|
6
6
|
}
|
|
7
|
-
export
|
|
7
|
+
export declare function EditableStringList({ label, values, setValues, onChange }: Props): import("react/jsx-runtime").JSX.Element;
|
|
@@ -2,7 +2,7 @@ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-run
|
|
|
2
2
|
import { useState } from 'react';
|
|
3
3
|
import { TextField, List, ListItem, ListItemText, IconButton, Stack } from '@mui/material';
|
|
4
4
|
import { Add, Check, Delete, Edit } from '@mui/icons-material';
|
|
5
|
-
export
|
|
5
|
+
export function EditableStringList({ label, values, setValues, onChange }) {
|
|
6
6
|
const [input, setInput] = useState('');
|
|
7
7
|
const [editIndex, setEditIndex] = useState(null);
|
|
8
8
|
const updateItems = (newItems) => {
|
|
@@ -8,5 +8,5 @@ interface Props {
|
|
|
8
8
|
value: string;
|
|
9
9
|
style?: any;
|
|
10
10
|
}
|
|
11
|
-
export
|
|
11
|
+
export declare function TextAreaField({ disabled, id, label, minRows, onChange, required, value, style }: Props): import("react/jsx-runtime").JSX.Element;
|
|
12
12
|
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { FormControl, InputLabel, TextareaAutosize } from '@mui/material';
|
|
3
|
-
export
|
|
3
|
+
export function TextAreaField({ disabled, id, label, minRows = 5, onChange = {}, required = false, value, style = {} }) {
|
|
4
4
|
// Render
|
|
5
5
|
return (_jsx("div", { style: style, children: _jsxs(FormControl, { fullWidth: true, children: [_jsx(InputLabel, { htmlFor: id, required: required, style: {
|
|
6
6
|
position: 'absolute',
|
|
@@ -4,5 +4,5 @@ interface Props {
|
|
|
4
4
|
value: string;
|
|
5
5
|
style?: any;
|
|
6
6
|
}
|
|
7
|
-
export
|
|
7
|
+
export declare function ViewLinkField({ label, href, value, style }: Props): import("react/jsx-runtime").JSX.Element;
|
|
8
8
|
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { Link, Typography } from '@mui/material';
|
|
3
|
-
export
|
|
3
|
+
export function ViewLinkField({ label, href, value, style = {} }) {
|
|
4
4
|
// Render
|
|
5
5
|
return (_jsxs("div", { style: style, children: [_jsx(Typography, { variant: 'caption', children: label }), _jsx(Typography, { variant: 'body1', children: _jsx(Link, { href: href, children: value }) })] }));
|
|
6
6
|
}
|
|
@@ -3,5 +3,5 @@ interface Props {
|
|
|
3
3
|
value: string;
|
|
4
4
|
style?: any;
|
|
5
5
|
}
|
|
6
|
-
export
|
|
6
|
+
export declare function ViewMarkdownField({ label, value, style }: Props): import("react/jsx-runtime").JSX.Element;
|
|
7
7
|
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import ReactMarkdown from 'react-markdown';
|
|
3
3
|
import { Typography } from '@mui/material';
|
|
4
|
-
export
|
|
4
|
+
export function ViewMarkdownField({ label, value, style = {} }) {
|
|
5
5
|
// Render
|
|
6
6
|
return (_jsxs("div", { style: style, children: [_jsx(Typography, { variant: 'caption', children: label }), _jsx("div", { style: { marginTop: '-1em' }, children: _jsx(ReactMarkdown, { children: value }) })] }));
|
|
7
7
|
}
|
|
@@ -3,5 +3,5 @@ interface Props {
|
|
|
3
3
|
value: string;
|
|
4
4
|
style?: any;
|
|
5
5
|
}
|
|
6
|
-
export
|
|
6
|
+
export declare function ViewTextField({ label, value, style }: Props): import("react/jsx-runtime").JSX.Element;
|
|
7
7
|
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { Typography } from '@mui/material';
|
|
3
|
-
export
|
|
3
|
+
export function ViewTextField({ label, value, style = {} }) {
|
|
4
4
|
// Render
|
|
5
5
|
return (_jsxs("div", { style: style, children: [_jsx(Typography, { variant: 'caption', children: label }), _jsx(Typography, { variant: 'body1', children: value })] }));
|
|
6
6
|
}
|
|
@@ -8,5 +8,5 @@ interface Props {
|
|
|
8
8
|
backgroundColor?: string;
|
|
9
9
|
style?: any;
|
|
10
10
|
}
|
|
11
|
-
export
|
|
11
|
+
export declare function LabeledIconButton({ disabled, icon, label, onClick, color, textColor, backgroundColor, style }: Props): import("react/jsx-runtime").JSX.Element;
|
|
12
12
|
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import { Box, Button, styled } from '@mui/material';
|
|
3
3
|
import { grey } from '@mui/material/colors';
|
|
4
|
-
export
|
|
4
|
+
export function LabeledIconButton({ disabled, icon, label, onClick, color = grey[700], textColor = grey[500], backgroundColor = grey[100], style = {} }) {
|
|
5
5
|
// Consts
|
|
6
6
|
const Icon = icon;
|
|
7
7
|
const ColorButton = styled(Button)(({ theme }) => ({
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
interface Props {
|
|
2
2
|
mailingListName: string;
|
|
3
3
|
}
|
|
4
|
-
export
|
|
4
|
+
export declare function MailingListSignUp({ mailingListName }: Props): import("react/jsx-runtime").JSX.Element;
|
|
5
5
|
export {};
|
|
@@ -3,7 +3,7 @@ import { useState } from 'react';
|
|
|
3
3
|
import { useMutation } from '@apollo/client/react';
|
|
4
4
|
import { mailingListSignupMutation } from '../../apollo/mailing-lists';
|
|
5
5
|
import { Alert, Button, TextField } from '@mui/material';
|
|
6
|
-
export
|
|
6
|
+
export function MailingListSignUp({ mailingListName }) {
|
|
7
7
|
// State
|
|
8
8
|
const [alertSeverity, setAlertSeverity] = useState(undefined);
|
|
9
9
|
const [message, setMessage] = useState(undefined);
|
|
@@ -4,5 +4,5 @@ interface Props {
|
|
|
4
4
|
notificationOpened: boolean;
|
|
5
5
|
setNotificationOpened: any;
|
|
6
6
|
}
|
|
7
|
-
export
|
|
7
|
+
export declare function ActionNotification({ message, autoHideDuration, notificationOpened, setNotificationOpened }: Props): import("react/jsx-runtime").JSX.Element;
|
|
8
8
|
export {};
|
|
@@ -2,7 +2,7 @@ import { jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
|
|
|
2
2
|
import CloseIcon from '@mui/icons-material/Close';
|
|
3
3
|
import IconButton from '@mui/material/IconButton';
|
|
4
4
|
import Snackbar from '@mui/material/Snackbar';
|
|
5
|
-
export
|
|
5
|
+
export function ActionNotification({ message, autoHideDuration, notificationOpened, setNotificationOpened }) {
|
|
6
6
|
const handleNotificationClose = (event, reason) => {
|
|
7
7
|
if (reason === 'clickaway') {
|
|
8
8
|
return;
|
|
@@ -3,5 +3,5 @@ interface Props {
|
|
|
3
3
|
resource: string;
|
|
4
4
|
setTechs: any;
|
|
5
5
|
}
|
|
6
|
-
export
|
|
6
|
+
export declare function LoadTechByFilter({ userProfileId, resource, setTechs }: Props): import("react/jsx-runtime").JSX.Element;
|
|
7
7
|
export {};
|
|
@@ -2,7 +2,7 @@ import { Fragment as _Fragment, jsx as _jsx } from "react/jsx-runtime";
|
|
|
2
2
|
import { useEffect } from 'react';
|
|
3
3
|
import { useQuery } from '@apollo/client/react';
|
|
4
4
|
import { getTechsQuery } from '../../apollo/techs';
|
|
5
|
-
export
|
|
5
|
+
export function LoadTechByFilter({ userProfileId, resource, setTechs }) {
|
|
6
6
|
// GraphQL
|
|
7
7
|
const { refetch: fetchTechsQuery } = useQuery(getTechsQuery, {
|
|
8
8
|
fetchPolicy: 'no-cache'
|
|
@@ -13,5 +13,5 @@ interface Props {
|
|
|
13
13
|
values: Tech[];
|
|
14
14
|
variant?: TextFieldVariants | undefined;
|
|
15
15
|
}
|
|
16
|
-
export
|
|
16
|
+
export declare function TechAutocomplete({ disabled, label, onChange, setValue, style, value, values, variant }: Props): import("react/jsx-runtime").JSX.Element;
|
|
17
17
|
export {};
|
|
@@ -2,7 +2,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
2
2
|
import Autocomplete from '@mui/material/Autocomplete';
|
|
3
3
|
import FormControl from '@mui/material/FormControl';
|
|
4
4
|
import TextField from '@mui/material/TextField';
|
|
5
|
-
export
|
|
5
|
+
export function TechAutocomplete({ disabled = false, label, onChange = () => { }, setValue, style = {}, value, values, variant = 'standard' }) {
|
|
6
6
|
const selectedTech = values.find((tech) => tech.id === value) || null;
|
|
7
7
|
return (_jsx(FormControl, { fullWidth: true, children: _jsx(Autocomplete, { disabled: disabled, value: selectedTech, onChange: (event, newValue) => {
|
|
8
8
|
// console.log(`newValue: ` + JSON.stringify(newValue))
|
|
@@ -3,5 +3,5 @@ interface Props {
|
|
|
3
3
|
tipTags: string[];
|
|
4
4
|
setTips: any;
|
|
5
5
|
}
|
|
6
|
-
export
|
|
6
|
+
export declare function LoadTips({ userProfileId, tipTags, setTips }: Props): import("react/jsx-runtime").JSX.Element;
|
|
7
7
|
export {};
|
|
@@ -2,7 +2,7 @@ import { Fragment as _Fragment, jsx as _jsx } from "react/jsx-runtime";
|
|
|
2
2
|
import { useEffect } from 'react';
|
|
3
3
|
import { useQuery } from '@apollo/client/react';
|
|
4
4
|
import { getTipsByUserProfileIdAndTagsQuery } from '../../apollo/tips';
|
|
5
|
-
export
|
|
5
|
+
export function LoadTips({ userProfileId, tipTags, setTips }) {
|
|
6
6
|
// GraphQL
|
|
7
7
|
const { refetch: fetchGetTipsByUserProfileIdAndTagsQuery } = useQuery(getTipsByUserProfileIdAndTagsQuery, {
|
|
8
8
|
fetchPolicy: 'no-cache'
|
|
@@ -7,5 +7,5 @@ interface Props {
|
|
|
7
7
|
style: any;
|
|
8
8
|
userProfileId: string;
|
|
9
9
|
}
|
|
10
|
-
export
|
|
10
|
+
export declare function Tip({ name, label, text, setFocusRef, setTipVisible, style, userProfileId }: Props): import("react/jsx-runtime").JSX.Element;
|
|
11
11
|
export {};
|
|
@@ -2,7 +2,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
2
2
|
import { useMutation } from '@apollo/client/react';
|
|
3
3
|
import { upsertTipGotItMutation } from '../../apollo/tips';
|
|
4
4
|
import { Button, Card, CardActions, CardContent, Typography } from '@mui/material';
|
|
5
|
-
export
|
|
5
|
+
export function Tip({ name, label, text, setFocusRef = undefined, setTipVisible, style = {}, userProfileId }) {
|
|
6
6
|
// GraphQL
|
|
7
7
|
const [sendUpsertTipGotItMutation] = useMutation(upsertTipGotItMutation, {
|
|
8
8
|
fetchPolicy: 'no-cache',
|
package/package.json
CHANGED
|
@@ -4,7 +4,7 @@ import Button from '@mui/material/Button'
|
|
|
4
4
|
import TextField from '@mui/material/TextField'
|
|
5
5
|
import Select from '@mui/material/Select'
|
|
6
6
|
import { useEffect, useState } from 'react'
|
|
7
|
-
import ActionNotification from '../notifications/action'
|
|
7
|
+
import { ActionNotification } from '../notifications/action'
|
|
8
8
|
import { RestApiService } from '../../services/rest-api/service'
|
|
9
9
|
import { FormControl, InputLabel, Typography } from '@mui/material'
|
|
10
10
|
import { countries } from '../../services/locale/countries'
|