@ltht-react/flag-detail 2.0.193 → 2.0.194
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/README.md +15 -15
- package/package.json +7 -7
- package/src/index.tsx +137 -137
- package/lib/index.d.ts +0 -10
- package/lib/index.js +0 -43
- package/lib/index.js.map +0 -1
package/README.md
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
# FlagDetail
|
|
2
|
-
|
|
3
|
-
<!-- STORY -->
|
|
4
|
-
|
|
5
|
-
### Import
|
|
6
|
-
|
|
7
|
-
```js
|
|
8
|
-
import FlagDetail from '@ltht-react/flag-detail'
|
|
9
|
-
```
|
|
10
|
-
|
|
11
|
-
### Usage
|
|
12
|
-
|
|
13
|
-
```jsx
|
|
14
|
-
<FlagDetail />
|
|
15
|
-
```
|
|
1
|
+
# FlagDetail
|
|
2
|
+
|
|
3
|
+
<!-- STORY -->
|
|
4
|
+
|
|
5
|
+
### Import
|
|
6
|
+
|
|
7
|
+
```js
|
|
8
|
+
import FlagDetail from '@ltht-react/flag-detail'
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
### Usage
|
|
12
|
+
|
|
13
|
+
```jsx
|
|
14
|
+
<FlagDetail />
|
|
15
|
+
```
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ltht-react/flag-detail",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.194",
|
|
4
4
|
"description": "ltht-react clinical FlagDetail component.",
|
|
5
5
|
"author": "LTHT",
|
|
6
6
|
"homepage": "",
|
|
@@ -28,12 +28,12 @@
|
|
|
28
28
|
"dependencies": {
|
|
29
29
|
"@emotion/react": "^11.0.0",
|
|
30
30
|
"@emotion/styled": "^11.0.0",
|
|
31
|
-
"@ltht-react/button": "^2.0.
|
|
32
|
-
"@ltht-react/styles": "^2.0.
|
|
33
|
-
"@ltht-react/type-detail": "^2.0.
|
|
34
|
-
"@ltht-react/types": "^2.0.
|
|
35
|
-
"@ltht-react/utils": "^2.0.
|
|
31
|
+
"@ltht-react/button": "^2.0.194",
|
|
32
|
+
"@ltht-react/styles": "^2.0.194",
|
|
33
|
+
"@ltht-react/type-detail": "^2.0.194",
|
|
34
|
+
"@ltht-react/types": "^2.0.194",
|
|
35
|
+
"@ltht-react/utils": "^2.0.194",
|
|
36
36
|
"react": "^18.2.0"
|
|
37
37
|
},
|
|
38
|
-
"gitHead": "
|
|
38
|
+
"gitHead": "2eb4b88fa2bc19baa1be9433dbe29fe1a947dc62"
|
|
39
39
|
}
|
package/src/index.tsx
CHANGED
|
@@ -1,137 +1,137 @@
|
|
|
1
|
-
import { FC } from 'react'
|
|
2
|
-
import styled from '@emotion/styled'
|
|
3
|
-
import { DetailViewType, Flag } from '@ltht-react/types'
|
|
4
|
-
import { getStringExtension } from '@ltht-react/utils'
|
|
5
|
-
import { Button, ButtonProps } from '@ltht-react/button'
|
|
6
|
-
import {
|
|
7
|
-
MOBILE_MAXIMUM_MEDIA_QUERY,
|
|
8
|
-
SMALL_SCREEN_MAXIMUM_MEDIA_QUERY,
|
|
9
|
-
TABLET_MINIMUM_MEDIA_QUERY,
|
|
10
|
-
} from '@ltht-react/styles'
|
|
11
|
-
|
|
12
|
-
import {
|
|
13
|
-
CodeableConceptDetail,
|
|
14
|
-
StringDetail,
|
|
15
|
-
PeriodDetail,
|
|
16
|
-
NarrativeDetail,
|
|
17
|
-
ResourceReferenceDetail,
|
|
18
|
-
CollapsibleDetailCollectionProps,
|
|
19
|
-
CollapsibleDetailCollection,
|
|
20
|
-
DatetimeDetail,
|
|
21
|
-
} from '@ltht-react/type-detail'
|
|
22
|
-
|
|
23
|
-
const StyledControlsContainer = styled.div`
|
|
24
|
-
display: flex;
|
|
25
|
-
margin: auto 10px auto 10px;
|
|
26
|
-
flex-direction: column;
|
|
27
|
-
|
|
28
|
-
${MOBILE_MAXIMUM_MEDIA_QUERY} {
|
|
29
|
-
margin: 10px 0 0 0;
|
|
30
|
-
flex-flow: row wrap;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
${SMALL_SCREEN_MAXIMUM_MEDIA_QUERY} {
|
|
34
|
-
margin: 10px 5px 0 0;
|
|
35
|
-
flex-direction: column;
|
|
36
|
-
}
|
|
37
|
-
`
|
|
38
|
-
const StyledButton = styled(Button)`
|
|
39
|
-
margin: 2px 0 2px 0;
|
|
40
|
-
font-size: 0.8em !important;
|
|
41
|
-
padding: 1px 5px;
|
|
42
|
-
|
|
43
|
-
${MOBILE_MAXIMUM_MEDIA_QUERY} {
|
|
44
|
-
margin: 2px 5px 2px 0;
|
|
45
|
-
width: fit-content;
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
${SMALL_SCREEN_MAXIMUM_MEDIA_QUERY} {
|
|
49
|
-
margin: 2px 0 2px 0;
|
|
50
|
-
width: 100%;
|
|
51
|
-
max-width: 200px;
|
|
52
|
-
}
|
|
53
|
-
`
|
|
54
|
-
const FullWidthSection = styled.div`
|
|
55
|
-
padding: 0.5rem 0 !important;
|
|
56
|
-
display: flex;
|
|
57
|
-
width: 100%;
|
|
58
|
-
justify-content: space-between;
|
|
59
|
-
margin-bottom: 1rem;
|
|
60
|
-
gap: 1rem;
|
|
61
|
-
|
|
62
|
-
${MOBILE_MAXIMUM_MEDIA_QUERY} {
|
|
63
|
-
flex-direction: column;
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
& > dl {
|
|
67
|
-
display: flex;
|
|
68
|
-
flex-direction: column;
|
|
69
|
-
}
|
|
70
|
-
`
|
|
71
|
-
|
|
72
|
-
const TopSection = styled(FullWidthSection)`
|
|
73
|
-
${TABLET_MINIMUM_MEDIA_QUERY} {
|
|
74
|
-
& dl:last-of-type {
|
|
75
|
-
margin-top: 0;
|
|
76
|
-
text-align: right;
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
`
|
|
80
|
-
const AuthorSection = styled(FullWidthSection)`
|
|
81
|
-
${TABLET_MINIMUM_MEDIA_QUERY} {
|
|
82
|
-
& > div:last-of-type > dl {
|
|
83
|
-
text-align: right;
|
|
84
|
-
}
|
|
85
|
-
}
|
|
86
|
-
`
|
|
87
|
-
|
|
88
|
-
const FlagDetail: FC<Props> = ({ flag, controls = [], viewType = DetailViewType.Compact }) => {
|
|
89
|
-
let buttons = <></>
|
|
90
|
-
if (controls.length) {
|
|
91
|
-
buttons = (
|
|
92
|
-
<StyledControlsContainer>
|
|
93
|
-
{controls.map((props, index) => (
|
|
94
|
-
<StyledButton key={index} {...props} />
|
|
95
|
-
))}
|
|
96
|
-
</StyledControlsContainer>
|
|
97
|
-
)
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
return (
|
|
101
|
-
<CollapsibleDetailCollection viewType={viewType}>
|
|
102
|
-
<TopSection>
|
|
103
|
-
<CodeableConceptDetail term="Code" concept={flag?.code} displayCode />
|
|
104
|
-
<CodeableConceptDetail term="Name" concept={flag?.code} />
|
|
105
|
-
</TopSection>
|
|
106
|
-
<TopSection>
|
|
107
|
-
<StringDetail term="Status" description={flag.status.toString()} />
|
|
108
|
-
<CodeableConceptDetail term="Category" concept={flag?.category} />
|
|
109
|
-
</TopSection>
|
|
110
|
-
<PeriodDetail period={flag?.period} />
|
|
111
|
-
<NarrativeDetail term="Description" narrative={flag?.text} />
|
|
112
|
-
<StringDetail
|
|
113
|
-
term="Advice"
|
|
114
|
-
description={getStringExtension(flag?.extension, 'https://leedsth.nhs.uk/alert/advice')}
|
|
115
|
-
parse={false}
|
|
116
|
-
/>
|
|
117
|
-
<AuthorSection>
|
|
118
|
-
<div>
|
|
119
|
-
<ResourceReferenceDetail term="Author" resourceReference={flag?.author} />
|
|
120
|
-
<DatetimeDetail term="Authored On" datetime={flag?.createdOn} />
|
|
121
|
-
</div>
|
|
122
|
-
<div>
|
|
123
|
-
<ResourceReferenceDetail term="Amended By" resourceReference={flag?.amendedBy} showIfEmpty={false} />
|
|
124
|
-
<DatetimeDetail term="Amended On" datetime={flag?.amendedOn} />
|
|
125
|
-
</div>
|
|
126
|
-
</AuthorSection>
|
|
127
|
-
{buttons}
|
|
128
|
-
</CollapsibleDetailCollection>
|
|
129
|
-
)
|
|
130
|
-
}
|
|
131
|
-
|
|
132
|
-
interface Props extends CollapsibleDetailCollectionProps {
|
|
133
|
-
flag: Flag
|
|
134
|
-
controls?: ButtonProps[]
|
|
135
|
-
}
|
|
136
|
-
|
|
137
|
-
export default FlagDetail
|
|
1
|
+
import { FC } from 'react'
|
|
2
|
+
import styled from '@emotion/styled'
|
|
3
|
+
import { DetailViewType, Flag } from '@ltht-react/types'
|
|
4
|
+
import { getStringExtension } from '@ltht-react/utils'
|
|
5
|
+
import { Button, ButtonProps } from '@ltht-react/button'
|
|
6
|
+
import {
|
|
7
|
+
MOBILE_MAXIMUM_MEDIA_QUERY,
|
|
8
|
+
SMALL_SCREEN_MAXIMUM_MEDIA_QUERY,
|
|
9
|
+
TABLET_MINIMUM_MEDIA_QUERY,
|
|
10
|
+
} from '@ltht-react/styles'
|
|
11
|
+
|
|
12
|
+
import {
|
|
13
|
+
CodeableConceptDetail,
|
|
14
|
+
StringDetail,
|
|
15
|
+
PeriodDetail,
|
|
16
|
+
NarrativeDetail,
|
|
17
|
+
ResourceReferenceDetail,
|
|
18
|
+
CollapsibleDetailCollectionProps,
|
|
19
|
+
CollapsibleDetailCollection,
|
|
20
|
+
DatetimeDetail,
|
|
21
|
+
} from '@ltht-react/type-detail'
|
|
22
|
+
|
|
23
|
+
const StyledControlsContainer = styled.div`
|
|
24
|
+
display: flex;
|
|
25
|
+
margin: auto 10px auto 10px;
|
|
26
|
+
flex-direction: column;
|
|
27
|
+
|
|
28
|
+
${MOBILE_MAXIMUM_MEDIA_QUERY} {
|
|
29
|
+
margin: 10px 0 0 0;
|
|
30
|
+
flex-flow: row wrap;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
${SMALL_SCREEN_MAXIMUM_MEDIA_QUERY} {
|
|
34
|
+
margin: 10px 5px 0 0;
|
|
35
|
+
flex-direction: column;
|
|
36
|
+
}
|
|
37
|
+
`
|
|
38
|
+
const StyledButton = styled(Button)`
|
|
39
|
+
margin: 2px 0 2px 0;
|
|
40
|
+
font-size: 0.8em !important;
|
|
41
|
+
padding: 1px 5px;
|
|
42
|
+
|
|
43
|
+
${MOBILE_MAXIMUM_MEDIA_QUERY} {
|
|
44
|
+
margin: 2px 5px 2px 0;
|
|
45
|
+
width: fit-content;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
${SMALL_SCREEN_MAXIMUM_MEDIA_QUERY} {
|
|
49
|
+
margin: 2px 0 2px 0;
|
|
50
|
+
width: 100%;
|
|
51
|
+
max-width: 200px;
|
|
52
|
+
}
|
|
53
|
+
`
|
|
54
|
+
const FullWidthSection = styled.div`
|
|
55
|
+
padding: 0.5rem 0 !important;
|
|
56
|
+
display: flex;
|
|
57
|
+
width: 100%;
|
|
58
|
+
justify-content: space-between;
|
|
59
|
+
margin-bottom: 1rem;
|
|
60
|
+
gap: 1rem;
|
|
61
|
+
|
|
62
|
+
${MOBILE_MAXIMUM_MEDIA_QUERY} {
|
|
63
|
+
flex-direction: column;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
& > dl {
|
|
67
|
+
display: flex;
|
|
68
|
+
flex-direction: column;
|
|
69
|
+
}
|
|
70
|
+
`
|
|
71
|
+
|
|
72
|
+
const TopSection = styled(FullWidthSection)`
|
|
73
|
+
${TABLET_MINIMUM_MEDIA_QUERY} {
|
|
74
|
+
& dl:last-of-type {
|
|
75
|
+
margin-top: 0;
|
|
76
|
+
text-align: right;
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
`
|
|
80
|
+
const AuthorSection = styled(FullWidthSection)`
|
|
81
|
+
${TABLET_MINIMUM_MEDIA_QUERY} {
|
|
82
|
+
& > div:last-of-type > dl {
|
|
83
|
+
text-align: right;
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
`
|
|
87
|
+
|
|
88
|
+
const FlagDetail: FC<Props> = ({ flag, controls = [], viewType = DetailViewType.Compact }) => {
|
|
89
|
+
let buttons = <></>
|
|
90
|
+
if (controls.length) {
|
|
91
|
+
buttons = (
|
|
92
|
+
<StyledControlsContainer>
|
|
93
|
+
{controls.map((props, index) => (
|
|
94
|
+
<StyledButton key={index} {...props} />
|
|
95
|
+
))}
|
|
96
|
+
</StyledControlsContainer>
|
|
97
|
+
)
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
return (
|
|
101
|
+
<CollapsibleDetailCollection viewType={viewType}>
|
|
102
|
+
<TopSection>
|
|
103
|
+
<CodeableConceptDetail term="Code" concept={flag?.code} displayCode />
|
|
104
|
+
<CodeableConceptDetail term="Name" concept={flag?.code} />
|
|
105
|
+
</TopSection>
|
|
106
|
+
<TopSection>
|
|
107
|
+
<StringDetail term="Status" description={flag.status.toString()} />
|
|
108
|
+
<CodeableConceptDetail term="Category" concept={flag?.category} />
|
|
109
|
+
</TopSection>
|
|
110
|
+
<PeriodDetail period={flag?.period} />
|
|
111
|
+
<NarrativeDetail term="Description" narrative={flag?.text} />
|
|
112
|
+
<StringDetail
|
|
113
|
+
term="Advice"
|
|
114
|
+
description={getStringExtension(flag?.extension, 'https://leedsth.nhs.uk/alert/advice')}
|
|
115
|
+
parse={false}
|
|
116
|
+
/>
|
|
117
|
+
<AuthorSection>
|
|
118
|
+
<div>
|
|
119
|
+
<ResourceReferenceDetail term="Author" resourceReference={flag?.author} />
|
|
120
|
+
<DatetimeDetail term="Authored On" datetime={flag?.createdOn} />
|
|
121
|
+
</div>
|
|
122
|
+
<div>
|
|
123
|
+
<ResourceReferenceDetail term="Amended By" resourceReference={flag?.amendedBy} showIfEmpty={false} />
|
|
124
|
+
<DatetimeDetail term="Amended On" datetime={flag?.amendedOn} />
|
|
125
|
+
</div>
|
|
126
|
+
</AuthorSection>
|
|
127
|
+
{buttons}
|
|
128
|
+
</CollapsibleDetailCollection>
|
|
129
|
+
)
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
interface Props extends CollapsibleDetailCollectionProps {
|
|
133
|
+
flag: Flag
|
|
134
|
+
controls?: ButtonProps[]
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
export default FlagDetail
|
package/lib/index.d.ts
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { FC } from 'react';
|
|
2
|
-
import { Flag } from '@ltht-react/types';
|
|
3
|
-
import { ButtonProps } from '@ltht-react/button';
|
|
4
|
-
import { CollapsibleDetailCollectionProps } from '@ltht-react/type-detail';
|
|
5
|
-
declare const FlagDetail: FC<Props>;
|
|
6
|
-
interface Props extends CollapsibleDetailCollectionProps {
|
|
7
|
-
flag: Flag;
|
|
8
|
-
controls?: ButtonProps[];
|
|
9
|
-
}
|
|
10
|
-
export default FlagDetail;
|
package/lib/index.js
DELETED
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __makeTemplateObject = (this && this.__makeTemplateObject) || function (cooked, raw) {
|
|
3
|
-
if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; }
|
|
4
|
-
return cooked;
|
|
5
|
-
};
|
|
6
|
-
var __assign = (this && this.__assign) || function () {
|
|
7
|
-
__assign = Object.assign || function(t) {
|
|
8
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
9
|
-
s = arguments[i];
|
|
10
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
11
|
-
t[p] = s[p];
|
|
12
|
-
}
|
|
13
|
-
return t;
|
|
14
|
-
};
|
|
15
|
-
return __assign.apply(this, arguments);
|
|
16
|
-
};
|
|
17
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
18
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
19
|
-
};
|
|
20
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
21
|
-
var jsx_runtime_1 = require("react/jsx-runtime");
|
|
22
|
-
var styled_1 = __importDefault(require("@emotion/styled"));
|
|
23
|
-
var types_1 = require("@ltht-react/types");
|
|
24
|
-
var utils_1 = require("@ltht-react/utils");
|
|
25
|
-
var button_1 = require("@ltht-react/button");
|
|
26
|
-
var styles_1 = require("@ltht-react/styles");
|
|
27
|
-
var type_detail_1 = require("@ltht-react/type-detail");
|
|
28
|
-
var StyledControlsContainer = styled_1.default.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n display: flex;\n margin: auto 10px auto 10px;\n flex-direction: column;\n\n ", " {\n margin: 10px 0 0 0;\n flex-flow: row wrap;\n }\n\n ", " {\n margin: 10px 5px 0 0;\n flex-direction: column;\n }\n"], ["\n display: flex;\n margin: auto 10px auto 10px;\n flex-direction: column;\n\n ", " {\n margin: 10px 0 0 0;\n flex-flow: row wrap;\n }\n\n ", " {\n margin: 10px 5px 0 0;\n flex-direction: column;\n }\n"])), styles_1.MOBILE_MAXIMUM_MEDIA_QUERY, styles_1.SMALL_SCREEN_MAXIMUM_MEDIA_QUERY);
|
|
29
|
-
var StyledButton = (0, styled_1.default)(button_1.Button)(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n margin: 2px 0 2px 0;\n font-size: 0.8em !important;\n padding: 1px 5px;\n\n ", " {\n margin: 2px 5px 2px 0;\n width: fit-content;\n }\n\n ", " {\n margin: 2px 0 2px 0;\n width: 100%;\n max-width: 200px;\n }\n"], ["\n margin: 2px 0 2px 0;\n font-size: 0.8em !important;\n padding: 1px 5px;\n\n ", " {\n margin: 2px 5px 2px 0;\n width: fit-content;\n }\n\n ", " {\n margin: 2px 0 2px 0;\n width: 100%;\n max-width: 200px;\n }\n"])), styles_1.MOBILE_MAXIMUM_MEDIA_QUERY, styles_1.SMALL_SCREEN_MAXIMUM_MEDIA_QUERY);
|
|
30
|
-
var FullWidthSection = styled_1.default.div(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n padding: 0.5rem 0 !important;\n display: flex;\n width: 100%;\n justify-content: space-between;\n margin-bottom: 1rem;\n gap: 1rem;\n\n ", " {\n flex-direction: column;\n }\n\n & > dl {\n display: flex;\n flex-direction: column;\n }\n"], ["\n padding: 0.5rem 0 !important;\n display: flex;\n width: 100%;\n justify-content: space-between;\n margin-bottom: 1rem;\n gap: 1rem;\n\n ", " {\n flex-direction: column;\n }\n\n & > dl {\n display: flex;\n flex-direction: column;\n }\n"])), styles_1.MOBILE_MAXIMUM_MEDIA_QUERY);
|
|
31
|
-
var TopSection = (0, styled_1.default)(FullWidthSection)(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n ", " {\n & dl:last-of-type {\n margin-top: 0;\n text-align: right;\n }\n }\n"], ["\n ", " {\n & dl:last-of-type {\n margin-top: 0;\n text-align: right;\n }\n }\n"])), styles_1.TABLET_MINIMUM_MEDIA_QUERY);
|
|
32
|
-
var AuthorSection = (0, styled_1.default)(FullWidthSection)(templateObject_5 || (templateObject_5 = __makeTemplateObject(["\n ", " {\n & > div:last-of-type > dl {\n text-align: right;\n }\n }\n"], ["\n ", " {\n & > div:last-of-type > dl {\n text-align: right;\n }\n }\n"])), styles_1.TABLET_MINIMUM_MEDIA_QUERY);
|
|
33
|
-
var FlagDetail = function (_a) {
|
|
34
|
-
var flag = _a.flag, _b = _a.controls, controls = _b === void 0 ? [] : _b, _c = _a.viewType, viewType = _c === void 0 ? types_1.DetailViewType.Compact : _c;
|
|
35
|
-
var buttons = (0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, {});
|
|
36
|
-
if (controls.length) {
|
|
37
|
-
buttons = ((0, jsx_runtime_1.jsx)(StyledControlsContainer, { children: controls.map(function (props, index) { return ((0, jsx_runtime_1.jsx)(StyledButton, __assign({}, props), index)); }) }));
|
|
38
|
-
}
|
|
39
|
-
return ((0, jsx_runtime_1.jsxs)(type_detail_1.CollapsibleDetailCollection, { viewType: viewType, children: [(0, jsx_runtime_1.jsxs)(TopSection, { children: [(0, jsx_runtime_1.jsx)(type_detail_1.CodeableConceptDetail, { term: "Code", concept: flag === null || flag === void 0 ? void 0 : flag.code, displayCode: true }), (0, jsx_runtime_1.jsx)(type_detail_1.CodeableConceptDetail, { term: "Name", concept: flag === null || flag === void 0 ? void 0 : flag.code })] }), (0, jsx_runtime_1.jsxs)(TopSection, { children: [(0, jsx_runtime_1.jsx)(type_detail_1.StringDetail, { term: "Status", description: flag.status.toString() }), (0, jsx_runtime_1.jsx)(type_detail_1.CodeableConceptDetail, { term: "Category", concept: flag === null || flag === void 0 ? void 0 : flag.category })] }), (0, jsx_runtime_1.jsx)(type_detail_1.PeriodDetail, { period: flag === null || flag === void 0 ? void 0 : flag.period }), (0, jsx_runtime_1.jsx)(type_detail_1.NarrativeDetail, { term: "Description", narrative: flag === null || flag === void 0 ? void 0 : flag.text }), (0, jsx_runtime_1.jsx)(type_detail_1.StringDetail, { term: "Advice", description: (0, utils_1.getStringExtension)(flag === null || flag === void 0 ? void 0 : flag.extension, 'https://leedsth.nhs.uk/alert/advice'), parse: false }), (0, jsx_runtime_1.jsxs)(AuthorSection, { children: [(0, jsx_runtime_1.jsxs)("div", { children: [(0, jsx_runtime_1.jsx)(type_detail_1.ResourceReferenceDetail, { term: "Author", resourceReference: flag === null || flag === void 0 ? void 0 : flag.author }), (0, jsx_runtime_1.jsx)(type_detail_1.DatetimeDetail, { term: "Authored On", datetime: flag === null || flag === void 0 ? void 0 : flag.createdOn })] }), (0, jsx_runtime_1.jsxs)("div", { children: [(0, jsx_runtime_1.jsx)(type_detail_1.ResourceReferenceDetail, { term: "Amended By", resourceReference: flag === null || flag === void 0 ? void 0 : flag.amendedBy, showIfEmpty: false }), (0, jsx_runtime_1.jsx)(type_detail_1.DatetimeDetail, { term: "Amended On", datetime: flag === null || flag === void 0 ? void 0 : flag.amendedOn })] })] }), buttons] }));
|
|
40
|
-
};
|
|
41
|
-
exports.default = FlagDetail;
|
|
42
|
-
var templateObject_1, templateObject_2, templateObject_3, templateObject_4, templateObject_5;
|
|
43
|
-
//# sourceMappingURL=index.js.map
|
package/l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