revert: removes expanded option, cards should always start minimized
This commit is contained in:
parent
a96acdd0d2
commit
973541e24f
7 changed files with 5 additions and 13 deletions
|
|
@ -102,7 +102,6 @@ export function parseTemplate(xml: string, id: string): Template {
|
|||
|
||||
const records: RecordDef[] = root.record.map((r: any) => ({
|
||||
type: r['@_type'],
|
||||
expanded: r['@_expanded'] === 'true',
|
||||
preamble: r.preamble?.trim(),
|
||||
fields: r.field.map(parseField)
|
||||
}));
|
||||
|
|
|
|||
|
|
@ -189,7 +189,6 @@ const testTemplate: Template = {
|
|||
records: [
|
||||
{
|
||||
type: 'public',
|
||||
expanded: true,
|
||||
fields: [
|
||||
{ label: 'Name', type: 'text' },
|
||||
{ label: 'Species', type: 'species' },
|
||||
|
|
@ -198,7 +197,6 @@ const testTemplate: Template = {
|
|||
},
|
||||
{
|
||||
type: 'employment',
|
||||
expanded: false,
|
||||
preamble: 'This information has been verified by employment agents.',
|
||||
fields: [
|
||||
{ label: 'Employment History', type: 'list' },
|
||||
|
|
@ -207,7 +205,6 @@ const testTemplate: Template = {
|
|||
},
|
||||
{
|
||||
type: 'medical',
|
||||
expanded: false,
|
||||
preamble: 'Protected by doctor-patient confidentiality.',
|
||||
fields: [
|
||||
{
|
||||
|
|
@ -220,7 +217,6 @@ const testTemplate: Template = {
|
|||
},
|
||||
{
|
||||
type: 'security',
|
||||
expanded: false,
|
||||
preamble: 'This information has been verified by employment agents.',
|
||||
fields: [
|
||||
{ label: 'Attitude Towards SCC', type: 'textarea' },
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ function makeTemplate(fields: any[]): Template {
|
|||
name: 'Test',
|
||||
description: '',
|
||||
schemaVersion: 1,
|
||||
records: [{ type: 'public', expanded: true, fields }]
|
||||
records: [{ type: 'public', fields }]
|
||||
};
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -15,7 +15,6 @@ const testTemplate: Template = {
|
|||
records: [
|
||||
{
|
||||
type: 'public',
|
||||
expanded: true,
|
||||
fields: [
|
||||
{ label: 'Name', type: 'text' },
|
||||
{ label: 'Species', type: 'species' }
|
||||
|
|
|
|||
|
|
@ -92,7 +92,6 @@ export type FieldDef =
|
|||
export interface RecordDef {
|
||||
type: string;
|
||||
preamble?: string;
|
||||
expanded: boolean;
|
||||
fields: FieldDef[];
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -10,7 +10,6 @@ const template = {
|
|||
records: [
|
||||
{
|
||||
type: 'public',
|
||||
expanded: true,
|
||||
fields: [
|
||||
{ label: 'Name', type: 'text' as const },
|
||||
{ label: 'Species', type: 'species' as const },
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue