mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-09-01 13:39:22 +03:00
Cleanup and split Enums
This commit is contained in:
parent
864da66b5f
commit
f3bfa0e8c1
31 changed files with 315 additions and 344 deletions
|
|
@ -1,4 +1,3 @@
|
|||
import { ContactPropertyType } from 'Common/Enums';
|
||||
import { pInt, pString } from 'Common/Utils';
|
||||
import { i18n } from 'Common/Translator';
|
||||
|
||||
|
|
@ -6,6 +5,37 @@ import { AbstractModel } from 'Knoin/AbstractModel';
|
|||
|
||||
const trim = text => null == text ? "" : (text + "").trim();
|
||||
|
||||
/**
|
||||
* @enum {number}
|
||||
*/
|
||||
export const ContactPropertyType = {
|
||||
Unknown: 0,
|
||||
|
||||
FullName: 10,
|
||||
|
||||
FirstName: 15,
|
||||
LastName: 16,
|
||||
MiddleName: 17,
|
||||
Nick: 18,
|
||||
|
||||
NamePrefix: 20,
|
||||
NameSuffix: 21,
|
||||
|
||||
Email: 30,
|
||||
Phone: 31,
|
||||
Web: 32,
|
||||
|
||||
Birthday: 40,
|
||||
|
||||
Facebook: 90,
|
||||
Skype: 91,
|
||||
GitHub: 92,
|
||||
|
||||
Note: 110,
|
||||
|
||||
Custom: 250
|
||||
};
|
||||
|
||||
export class ContactPropertyModel extends AbstractModel {
|
||||
/**
|
||||
* @param {number=} type = Enums.ContactPropertyType.Unknown
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue