@voplus/morpho-workspace 6.0.113 → 6.0.114
Sign up to get free protection for your applications and to get access to all the features.
- package/es/components/AutoSequenceLink/index.d.ts +1 -0
- package/es/components/AutoSequenceLink/index.js +1 -2
- package/es/components/AutoSequenceLink/index.js.map +1 -1
- package/es/modules/notification/components/NewNotificationForm/index.less +1 -1
- package/es/modules/work/work-type/components/WorkTypeProperties/Properties.js +5 -5
- package/es/modules/work/work-type/components/WorkTypeProperties/Properties.js.map +1 -1
- package/es/modules/work/work-type/components/WorkTypeProperties/WorkTypePropertiesCard.js +1 -1
- package/es/modules/work/work-type/components/WorkTypeProperties/WorkTypePropertiesCard.js.map +1 -1
- package/es/modules/work/work-type/components/WorkTypeProperties/index.js +11 -19
- package/es/modules/work/work-type/components/WorkTypeProperties/index.js.map +1 -1
- package/es/modules/work/work-type/components/WorkTypeProperties/index.less +12 -0
- package/es/modules/work/work-type/pages/WorkTypePage/index.less +4 -3
- package/package.json +1 -1
@@ -2,6 +2,7 @@ import React from "react";
|
|
2
2
|
import { ISequenceInfo, SequenceEditOptions } from "../../data/worktype";
|
3
3
|
declare const AutoSequenceLink: (props: {
|
4
4
|
sequence?: ISequenceInfo;
|
5
|
+
style?: React.CSSProperties;
|
5
6
|
onSubmit?: (Sequence: SequenceEditOptions) => void;
|
6
7
|
}) => React.JSX.Element;
|
7
8
|
export default AutoSequenceLink;
|
@@ -1,12 +1,11 @@
|
|
1
1
|
import React, { useState } from "react";
|
2
2
|
import { observe } from "@voplus/morpho-ui";
|
3
3
|
import AutoSequenceDialog from "../AutoSequenceDialog";
|
4
|
-
import classnames from "classnames";
|
5
4
|
const AutoSequenceLink = (props) => {
|
6
5
|
const [open, setOpen] = useState(false);
|
7
6
|
const { sequence } = props;
|
8
7
|
return observe(() => (React.createElement(React.Fragment, null,
|
9
|
-
React.createElement("span", {
|
8
|
+
React.createElement("span", { style: { cursor: "pointer" }, onClick: () => setOpen(true) }, (sequence === null || sequence === void 0 ? void 0 : sequence.format) ? (React.createElement("span", { style: props.style }, sequence.format)) : (React.createElement("span", { className: "add-info-style" }, "Add NumberFormat"))),
|
10
9
|
open && (React.createElement(AutoSequenceDialog, { sequence: sequence, onCancel: () => setOpen(false), onSubmit: (data) => {
|
11
10
|
var _a;
|
12
11
|
setOpen(false);
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/AutoSequenceLink/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/AutoSequenceLink/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAE5C,OAAO,kBAAkB,MAAM,uBAAuB,CAAC;AAEvD,MAAM,gBAAgB,GAAG,CAAC,KAIzB,EAAE,EAAE;IACJ,MAAM,CAAC,IAAI,EAAE,OAAO,CAAC,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAC;IACxC,MAAM,EAAE,QAAQ,EAAE,GAAG,KAAK,CAAC;IAE3B,OAAO,OAAO,CAAC,GAAG,EAAE,CAAC,CACpB;QACC,8BAAM,KAAK,EAAE,EAAE,MAAM,EAAE,SAAS,EAAE,EAAE,OAAO,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC,IAC9D,CAAA,QAAQ,aAAR,QAAQ,uBAAR,QAAQ,CAAE,MAAM,EAAC,CAAC,CAAC,CACnB,8BAAM,KAAK,EAAE,KAAK,CAAC,KAAK,IAAG,QAAQ,CAAC,MAAM,CAAQ,CAClD,CAAC,CAAC,CAAC,CACH,8BAAM,SAAS,EAAC,gBAAgB,uBAAwB,CACxD,CACK;QACN,IAAI,IAAI,CACR,oBAAC,kBAAkB,IAClB,QAAQ,EAAE,QAAQ,EAClB,QAAQ,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,KAAK,CAAC,EAC9B,QAAQ,EAAE,CAAC,IAAI,EAAE,EAAE;;gBAClB,OAAO,CAAC,KAAK,CAAC,CAAC;gBACf,MAAA,KAAK,CAAC,QAAQ,sDAAG,IAAI,CAAC,CAAC;YACxB,CAAC,GACA,CACF,CACC,CACH,CAAC,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,gBAAgB,CAAC"}
|
@@ -7,7 +7,7 @@ import { useApplicationContext } from "@voplus/morpho-data";
|
|
7
7
|
import { useWorkType, useWorkTypeStore } from "../../../../../data/worktype";
|
8
8
|
import NodeLink from "../../../../../controls/NodeLink";
|
9
9
|
import AvatarList from "@voplus/morpho-org/es/components/AvatarList";
|
10
|
-
import DocumentReference from "@voplus/morpho-document/es/controls/DocumentReference
|
10
|
+
import DocumentReference from "@voplus/morpho-document/es/controls/DocumentReference";
|
11
11
|
import DocumentSelectDialog from "@voplus/morpho-document/es/components/DocumentSelectDialog";
|
12
12
|
import ChangeWorkDefaultFolderDialog from "../ChangeWorkDefaultFolderDialog";
|
13
13
|
import WorkTypeStatusLabel from "../../controls/WorkTypeStatusLabel";
|
@@ -29,7 +29,7 @@ const Properties = (props) => {
|
|
29
29
|
case "Work Space":
|
30
30
|
return (React.createElement(NodeLink, { node: worktype === null || worktype === void 0 ? void 0 : worktype.workspace, url: `/workspaces/${(_a = worktype.workspace) === null || _a === void 0 ? void 0 : _a.id}` }));
|
31
31
|
case "Number Format":
|
32
|
-
return (React.createElement(AutoSequenceLink, { sequence: worktype.sequence, onSubmit: (sequence) => store.edit(worktype.id, { data: { Sequence: sequence } }) }));
|
32
|
+
return (React.createElement(AutoSequenceLink, { style: { color: "#868686" }, sequence: worktype.sequence, onSubmit: (sequence) => store.edit(worktype.id, { data: { Sequence: sequence } }) }));
|
33
33
|
case "Status":
|
34
34
|
return (React.createElement(WorkTypeStatusLabel, { editable: true, status: worktype.status, onChange: (status) => {
|
35
35
|
store.edit(worktype.id, { data: { Status: status }, error: "message" });
|
@@ -37,15 +37,15 @@ const Properties = (props) => {
|
|
37
37
|
case "Default Folder":
|
38
38
|
return (React.createElement(InlineEdit, { showEditIcon: true, defaultValue: `&${(_b = state.worktype.defaultFolder) === null || _b === void 0 ? void 0 : _b.name}`, editable: false, content: (v) => {
|
39
39
|
var _a;
|
40
|
-
return (React.createElement("div", null, ((_a = state.worktype.defaultFolder) === null || _a === void 0 ? void 0 : _a.id) ? (React.createElement(DocumentReference, {
|
40
|
+
return (React.createElement("div", null, ((_a = state.worktype.defaultFolder) === null || _a === void 0 ? void 0 : _a.id) ? (React.createElement(DocumentReference, { type: "link", id: state.worktype.defaultFolder.id })) : (React.createElement("span", { className: "add-info-style" }, "Add Default Folder"))));
|
41
41
|
}, onEditIconClick: () => runInAction(() => (state.folderEdit = true)) }));
|
42
42
|
case "Documentation":
|
43
43
|
return (React.createElement(InlineEdit, { showEditIcon: true, defaultValue: `&${(_c = state.worktype.document) === null || _c === void 0 ? void 0 : _c.name}`, editable: false, content: (v) => {
|
44
44
|
var _a;
|
45
|
-
return (React.createElement("div", null, ((_a = state.worktype.document) === null || _a === void 0 ? void 0 : _a.id) ? (React.createElement(DocumentReference, {
|
45
|
+
return (React.createElement("div", null, ((_a = state.worktype.document) === null || _a === void 0 ? void 0 : _a.id) ? (React.createElement(DocumentReference, { type: "link", id: state.worktype.document.id })) : (React.createElement("span", { className: "add-info-style" }, "Add Documentation"))));
|
46
46
|
}, onEditIconClick: () => runInAction(() => (state.documentationEdit = true)) }));
|
47
47
|
case "Default Due":
|
48
|
-
return (React.createElement(InlineEdit, { defaultValue: worktype.defaultDue, content: (v) => (React.createElement("
|
48
|
+
return (React.createElement(InlineEdit, { defaultValue: worktype.defaultDue, content: (v) => worktype.defaultDue !== undefined ? (React.createElement("span", { className: "properties-value" }, worktype.defaultDue === 0 ? "Same day" : `${worktype.defaultDue} days`)) : (React.createElement("span", { className: "add-info-style" }, "Add default due in days")), onSave: (value) => store.edit(worktype.id, { data: { DefaultDue: value }, error: "message" }) }));
|
49
49
|
case "Requester":
|
50
50
|
return (React.createElement(AvatarList, { organizationId: user.info.organizationId, multiple: true, buttonText: "Ok", list: worktype.requester, onChange: (ids) => {
|
51
51
|
store.edit(worktype.id, { data: { RequesterIds: ids }, error: "message" });
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Properties.js","sourceRoot":"","sources":["../../../../../../src/modules/work/work-type/components/WorkTypeProperties/Properties.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AACxD,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,EAAE,MAAM,EAAE,MAAM,MAAM,CAAC;AAC9B,OAAO,EAAE,WAAW,EAAE,MAAM,MAAM,CAAC;AACnC,OAAO,EAAE,qBAAqB,EAAE,MAAM,qBAAqB,CAAC;AAC5D,OAAO,EAAE,WAAW,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC;AAC7E,OAAO,QAAQ,MAAM,kCAAkC,CAAC;AACxD,OAAO,UAAU,MAAM,6CAA6C,CAAC;AACrE,OAAO,iBAAiB,MAAM
|
1
|
+
{"version":3,"file":"Properties.js","sourceRoot":"","sources":["../../../../../../src/modules/work/work-type/components/WorkTypeProperties/Properties.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AACxD,OAAO,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAChC,OAAO,EAAE,MAAM,EAAE,MAAM,MAAM,CAAC;AAC9B,OAAO,EAAE,WAAW,EAAE,MAAM,MAAM,CAAC;AACnC,OAAO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EAAE,IAAI,EAAE,EAAE,WAAW,EAAE,GAAG,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC,CAAC;oBAC3E,CAAC,GACA,CACF,CAAC;YACH,KAAK,eAAe;gBACnB,OAAO,CACN,oBAAC,UAAU,IACV,cAAc,EAAE,IAAI,CAAC,IAAI,CAAC,cAAc,EACxC,QAAQ,QACR,UAAU,EAAC,IAAI,EACf,IAAI,EAAE,QAAQ,CAAC,MAAM,EACrB,QAAQ,EAAE,CAAC,GAAa,EAAE,EAAE;wBAC3B,KAAK,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,EAAE,EAAE,IAAI,EAAE,EAAE,QAAQ,EAAE,GAAG,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC,CAAC;oBACxE,CAAC,GACA,CACF,CAAC;YACH,KAAK,aAAa;gBACjB,OAAO,CACN,oBAAC,MAAM,IACN,OAAO,EAAE,QAAQ,CAAC,UAAU,EAC5B,QAAQ,EAAE,CAAC,OAAO,EAAE,EAAE,CACrB,KAAK,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,EAAE,EAAE,IAAI,EAAE,EAAE,UAAU,EAAE,OAAO,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC,GAE5E,CACF,CAAC;QACJ,CAAC;IACF,CAAC;AACF,CAAC,CAAC;AAEF,eAAe,UAAU,CAAC"}
|
@@ -8,7 +8,7 @@ const WorkTypePropertiesCard = (props) => {
|
|
8
8
|
const { id, workTypeProperties } = props;
|
9
9
|
const worktype = useWorkType(id);
|
10
10
|
return observe(() => (React.createElement(Skeleton, { active: true, loading: !worktype.loaded },
|
11
|
-
React.createElement(PropertiesCard, { title: "Work Type Details", cardList: workTypeProperties, cardItem: (item) => React.createElement(Properties, { id: id, propertiesName: item }) }))));
|
11
|
+
React.createElement(PropertiesCard, { className: "work-type-properties-card", title: "Work Type Details", cardList: workTypeProperties, cardItem: (item) => React.createElement(Properties, { id: id, propertiesName: item }) }))));
|
12
12
|
};
|
13
13
|
WorkTypePropertiesCard.defaultProps = {
|
14
14
|
workTypeProperties: [
|
package/es/modules/work/work-type/components/WorkTypeProperties/WorkTypePropertiesCard.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"WorkTypePropertiesCard.js","sourceRoot":"","sources":["../../../../../../src/modules/work/work-type/components/WorkTypeProperties/WorkTypePropertiesCard.tsx"],"names":[],"mappings":"AAAA,OAAO,UAAsC,MAAM,cAAc,CAAC;AAElE,OAAO,cAAc,MAAM,8CAA8C,CAAC;AAC1E,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,QAAQ,EAAE,MAAM,MAAM,CAAC;AAChC,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAE3D,MAAM,sBAAsB,GAAG,CAAC,KAG/B,EAAE,EAAE;IACJ,MAAM,EAAE,EAAE,EAAE,kBAAkB,EAAE,GAAG,KAAK,CAAC;IACzC,MAAM,QAAQ,GAAG,WAAW,CAAC,EAAE,CAAC,CAAC;IAEjC,OAAO,OAAO,CAAC,GAAG,EAAE,CAAC,CACpB,oBAAC,QAAQ,IAAC,MAAM,QAAC,OAAO,EAAE,CAAC,QAAQ,CAAC,MAAM;QACzC,oBAAC,cAAc,IACd,KAAK,EAAC,mBAAmB,EACzB,QAAQ,EAAE,kBAAkB,EAC5B,QAAQ,EAAE,CAAC,IAA4B,EAAE,EAAE,CAAC,oBAAC,UAAU,IAAC,EAAE,EAAE,EAAE,EAAE,cAAc,EAAE,IAAI,GAAI,GACvF,CACQ,CACX,CAAC,CAAC;AACJ,CAAC,CAAC;AAEF,sBAAsB,CAAC,YAAY,GAAG;IACrC,kBAAkB,EAAE;QACnB,EAAE,GAAG,EAAE,YAAY,EAAE;QACrB,EAAE,GAAG,EAAE,eAAe,EAAE;QACxB,EAAE,GAAG,EAAE,QAAQ,EAAE;QACjB,EAAE,GAAG,EAAE,gBAAgB,EAAE;QACzB,EAAE,GAAG,EAAE,eAAe,EAAE;QACxB,EAAE,GAAG,EAAE,aAAa,EAAE;QACtB,EAAE,GAAG,EAAE,WAAW,EAAE;QACpB,EAAE,GAAG,EAAE,WAAW,EAAE;QACpB,EAAE,GAAG,EAAE,eAAe,EAAE;QACxB,EAAE,GAAG,EAAE,aAAa,EAAE;KACtB;CACD,CAAC;AAEF,eAAe,sBAAsB,CAAC"}
|
1
|
+
{"version":3,"file":"WorkTypePropertiesCard.js","sourceRoot":"","sources":["../../../../../../src/modules/work/work-type/components/WorkTypeProperties/WorkTypePropertiesCard.tsx"],"names":[],"mappings":"AAAA,OAAO,UAAsC,MAAM,cAAc,CAAC;AAElE,OAAO,cAAc,MAAM,8CAA8C,CAAC;AAC1E,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,QAAQ,EAAE,MAAM,MAAM,CAAC;AAChC,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAE3D,MAAM,sBAAsB,GAAG,CAAC,KAG/B,EAAE,EAAE;IACJ,MAAM,EAAE,EAAE,EAAE,kBAAkB,EAAE,GAAG,KAAK,CAAC;IACzC,MAAM,QAAQ,GAAG,WAAW,CAAC,EAAE,CAAC,CAAC;IAEjC,OAAO,OAAO,CAAC,GAAG,EAAE,CAAC,CACpB,oBAAC,QAAQ,IAAC,MAAM,QAAC,OAAO,EAAE,CAAC,QAAQ,CAAC,MAAM;QACzC,oBAAC,cAAc,IACd,SAAS,EAAC,2BAA2B,EACrC,KAAK,EAAC,mBAAmB,EACzB,QAAQ,EAAE,kBAAkB,EAC5B,QAAQ,EAAE,CAAC,IAA4B,EAAE,EAAE,CAAC,oBAAC,UAAU,IAAC,EAAE,EAAE,EAAE,EAAE,cAAc,EAAE,IAAI,GAAI,GACvF,CACQ,CACX,CAAC,CAAC;AACJ,CAAC,CAAC;AAEF,sBAAsB,CAAC,YAAY,GAAG;IACrC,kBAAkB,EAAE;QACnB,EAAE,GAAG,EAAE,YAAY,EAAE;QACrB,EAAE,GAAG,EAAE,eAAe,EAAE;QACxB,EAAE,GAAG,EAAE,QAAQ,EAAE;QACjB,EAAE,GAAG,EAAE,gBAAgB,EAAE;QACzB,EAAE,GAAG,EAAE,eAAe,EAAE;QACxB,EAAE,GAAG,EAAE,aAAa,EAAE;QACtB,EAAE,GAAG,EAAE,WAAW,EAAE;QACpB,EAAE,GAAG,EAAE,WAAW,EAAE;QACpB,EAAE,GAAG,EAAE,eAAe,EAAE;QACxB,EAAE,GAAG,EAAE,aAAa,EAAE;KACtB;CACD,CAAC;AAEF,eAAe,sBAAsB,CAAC"}
|
@@ -1,35 +1,27 @@
|
|
1
|
-
import { InlineEdit, observe } from "@voplus/morpho-ui";
|
2
|
-
import Properties from "./Properties";
|
3
1
|
import React, { useState } from "react";
|
2
|
+
import { State } from "./state";
|
3
|
+
import { Scrollbars } from "react-custom-scrollbars-2";
|
4
|
+
import { InlineEdit, observe } from "@voplus/morpho-ui";
|
4
5
|
import { useWorkType, useWorkTypeStore } from "../../../../../data/worktype";
|
5
6
|
import PropertiesSection from "@voplus/morpho-ui/es/controls/PropertiesSection";
|
7
|
+
import Properties from "./Properties";
|
6
8
|
import Prop from "@voplus/morpho-ui/es/controls/Prop";
|
7
|
-
import { Form } from "antd";
|
8
|
-
import { Scrollbars } from "react-custom-scrollbars-2";
|
9
|
-
import { State } from "./state";
|
10
9
|
import classnames from "classnames";
|
10
|
+
import styles from "./index.less";
|
11
11
|
const WorkTypeProperties = (props) => {
|
12
|
+
const { id, workTypeProperties } = props;
|
12
13
|
/** 加class name 为了方便做integration tests */
|
13
14
|
const classId = "workType-properties";
|
14
|
-
const
|
15
|
+
const worktype = useWorkType(props.id);
|
15
16
|
const store = useWorkTypeStore();
|
16
17
|
const [state] = useState(new State(store));
|
17
|
-
const worktype = useWorkType(props.id);
|
18
18
|
state.update(worktype);
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
React.createElement("div", { className: "title" },
|
23
|
-
React.createElement(InlineEdit, { defaultValue: worktype === null || worktype === void 0 ? void 0 : worktype.name, content: (v) => React.createElement("div", null, worktype === null || worktype === void 0 ? void 0 : worktype.name), onSave: (value) => state.save(value, worktype.name, { Name: value }) })))),
|
19
|
+
return observe(() => (React.createElement("div", { className: classnames(styles["work-type-properties"], "properties-list") },
|
20
|
+
props.header && (React.createElement("div", { className: "work-type-properties-type-header" },
|
21
|
+
React.createElement(InlineEdit, { defaultValue: worktype === null || worktype === void 0 ? void 0 : worktype.name, content: (v) => React.createElement("div", { className: "work-type-properties-type-name" }, worktype === null || worktype === void 0 ? void 0 : worktype.name), onSave: (value) => state.save(value, worktype.name, { Name: value }) }))),
|
24
22
|
React.createElement(Scrollbars, { autoHide: true },
|
25
|
-
React.createElement(PropertiesSection, { properties: () => workTypeProperties === null || workTypeProperties === void 0 ? void 0 : workTypeProperties.map((i) => (React.createElement(Prop, { key: i, label: i, className: `${classId}-${i}` },
|
23
|
+
React.createElement(PropertiesSection, { title: "WORK TYPE PROPERTIES", properties: () => workTypeProperties === null || workTypeProperties === void 0 ? void 0 : workTypeProperties.map((i) => (React.createElement(Prop, { key: i, label: i, className: `${classId}-${i}` },
|
26
24
|
React.createElement(Properties, { id: id, propertiesName: i })))) })))));
|
27
|
-
/** 转换 */
|
28
|
-
function titleCase(str) {
|
29
|
-
const str1 = str.replace(" ", "");
|
30
|
-
const newStr = str1.slice(0, 1).toLowerCase() + str1.slice(1);
|
31
|
-
return newStr;
|
32
|
-
}
|
33
25
|
};
|
34
26
|
WorkTypeProperties.defaultProps = {
|
35
27
|
header: true,
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/modules/work/work-type/components/WorkTypeProperties/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,
|
1
|
+
{"version":3,"file":"index.js","sourceR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|
|
49
|
+
.work-type-properties-card {
|
50
|
+
margin-top: 1.25rem;
|
51
|
+
}
|
52
|
+
|
52
53
|
.description-editor {
|
53
54
|
padding-top: 0 !important;
|
54
55
|
|