Skip to content

Commit

Permalink
feat(core/forms): Added Signature field and field type.
Browse files Browse the repository at this point in the history
  • Loading branch information
Marco Tozzi authored and robzan8 committed Oct 16, 2023
1 parent d6e023b commit cb700ec
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 0 deletions.
1 change: 1 addition & 0 deletions projects/core/forms/src/interface/fields/field-type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,5 +43,6 @@ export enum AjfFieldType {
Image,
VideoUrl,
Range,
Signature,
LENGTH,
}
2 changes: 2 additions & 0 deletions projects/core/forms/src/interface/fields/field.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ import {AjfImageField} from './image-field';
import {AjfMultipleChoiceField} from './multiple-choice-field';
import {AjfNumberField} from './number-field';
import {AjfRangeField} from './range-field';
import {AjfSignatureField} from './signature-field';
import {AjfSingleChoiceField} from './single-choice-field';
import {AjfStringField} from './string-field';
import {AjfTableField} from './table-field';
Expand All @@ -53,6 +54,7 @@ export type AjfField<T = any> =
| AjfMultipleChoiceField<T>
| AjfNumberField
| AjfRangeField
| AjfSignatureField
| AjfSingleChoiceField<T>
| AjfStringField
| AjfTableField
Expand Down
31 changes: 31 additions & 0 deletions projects/core/forms/src/interface/fields/signature-field.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
/**
* @license
* Copyright (C) Gnucoop soc. coop.
*
* This file is part of the Advanced JSON forms (ajf).
*
* Advanced JSON forms (ajf) is free software: you can redistribute it and/or
* modify it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the License,
* or (at your option) any later version.
*
* Advanced JSON forms (ajf) is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero
* General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with Advanced JSON forms (ajf).
* If not, see http://www.gnu.org/licenses/.
*
*/

import {AjfBaseField} from './base-field';
import {AjfFieldType} from './field-type';

/**
* An AjfField of type Signature.
*/
export interface AjfSignatureField extends AjfBaseField {
fieldType: AjfFieldType.Signature;
}

0 comments on commit cb700ec

Please sign in to comment.