fix(contacts): refactor wrong ContactFieldTypes

This commit is contained in:
Daniel Sogl 2018-03-16 20:25:12 +01:00 committed by GitHub
parent 9ae9f19717
commit f607a03c9b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,10 +1,9 @@
import { Injectable } from '@angular/core';
import { CordovaInstance, InstanceProperty, Plugin, getPromise, InstanceCheck, checkAvailability, CordovaCheck, IonicNativePlugin } from '@ionic-native/core'; import { CordovaInstance, InstanceProperty, Plugin, getPromise, InstanceCheck, checkAvailability, CordovaCheck, IonicNativePlugin } from '@ionic-native/core';
declare const window: any, declare const window: any,
navigator: any; navigator: any;
export type ContactFieldType = '*' | 'addresses' | 'birthday' | 'categories' | 'country' | 'department' | 'displayName' | 'emails' | 'familyName' | 'formatted' | 'givenName' | 'honorificPrefix' | 'honorificSuffix' | 'id' | 'ims' | 'locality' | 'middleName' | 'name' | 'nickname' | 'note' | 'organizations' | 'phoneNumbers' | 'photos' | 'postalCode' | 'region' | 'streetAddress' | 'title' | 'urls'; export type ContactFieldType = '*' | 'addresses' | 'birthday' | 'categories' | 'country' | 'department' | 'displayName' | 'emails' | 'name.familyName' | 'name.formatted' | 'name.givenName' | 'name.honorificPrefix' | 'name.honorificSuffix' | 'id' | 'ims' | 'locality' | 'name.middleName' | 'name' | 'nickname' | 'note' | 'organizations' | 'phoneNumbers' | 'photos' | 'postalCode' | 'region' | 'streetAddress' | 'title' | 'urls';
export interface IContactProperties { export interface IContactProperties {
@ -261,10 +260,6 @@ export class ContactFindOptions implements IContactFindOptions {
* @description * @description
* Access and manage Contacts on the device. * Access and manage Contacts on the device.
* *
* @deprecated
* This plugin is being deprecated. No more work will be done on this plugin by the Cordova development community.
* You can continue to use this plugin and it should work as-is in the future but any more arising issues will not be fixed by the Cordova community.
*
* @usage * @usage
* *
* ```typescript * ```typescript
@ -298,9 +293,8 @@ export class ContactFindOptions implements IContactFindOptions {
plugin: 'cordova-plugin-contacts', plugin: 'cordova-plugin-contacts',
pluginRef: 'navigator.contacts', pluginRef: 'navigator.contacts',
repo: 'https://github.com/apache/cordova-plugin-contacts', repo: 'https://github.com/apache/cordova-plugin-contacts',
platforms: ['Android', 'iOS', 'Windows'] platforms: ['Android', 'BlackBerry 10', 'Browser', 'Firefox OS', 'iOS', 'Ubuntu', 'Windows', 'Windows 8', 'Windows Phone']
}) })
@Injectable()
export class Contacts extends IonicNativePlugin { export class Contacts extends IonicNativePlugin {
/** /**