Auto-fix lint errors

This commit is contained in:
J. Ryan Stinnett 2021-06-29 13:11:58 +01:00
parent 4c5720a573
commit ae0a8b8da4
625 changed files with 3170 additions and 3232 deletions

View file

@ -15,8 +15,8 @@ See the License for the specific language governing permissions and
limitations under the License.
*/
import {PushRuleVectorState, State} from "./PushRuleVectorState";
import {IExtendedPushRule, IRuleSets} from "./types";
import { PushRuleVectorState, State } from "./PushRuleVectorState";
import { IExtendedPushRule, IRuleSets } from "./types";
export interface IContentRules {
vectorState: State;

View file

@ -15,7 +15,7 @@ See the License for the specific language governing permissions and
limitations under the License.
*/
import {Action, Actions} from "./types";
import { Action, Actions } from "./types";
interface IEncodedActions {
notify: boolean;
@ -37,12 +37,12 @@ export class NotificationUtils {
if (notify) {
const actions: Action[] = [Actions.Notify];
if (sound) {
actions.push({"set_tweak": "sound", "value": sound});
actions.push({ "set_tweak": "sound", "value": sound });
}
if (highlight) {
actions.push({"set_tweak": "highlight"});
actions.push({ "set_tweak": "highlight" });
} else {
actions.push({"set_tweak": "highlight", "value": false});
actions.push({ "set_tweak": "highlight", "value": false });
}
return actions;
} else {

View file

@ -15,9 +15,9 @@ See the License for the specific language governing permissions and
limitations under the License.
*/
import {StandardActions} from "./StandardActions";
import {NotificationUtils} from "./NotificationUtils";
import {IPushRule} from "./types";
import { StandardActions } from "./StandardActions";
import { NotificationUtils } from "./NotificationUtils";
import { IPushRule } from "./types";
export enum State {
/** The push rule is disabled */

View file

@ -15,16 +15,16 @@ See the License for the specific language governing permissions and
limitations under the License.
*/
import {NotificationUtils} from "./NotificationUtils";
import { NotificationUtils } from "./NotificationUtils";
const encodeActions = NotificationUtils.encodeActions;
export class StandardActions {
static ACTION_NOTIFY = encodeActions({notify: true});
static ACTION_NOTIFY_DEFAULT_SOUND = encodeActions({notify: true, sound: "default"});
static ACTION_NOTIFY_RING_SOUND = encodeActions({notify: true, sound: "ring"});
static ACTION_HIGHLIGHT = encodeActions({notify: true, highlight: true});
static ACTION_HIGHLIGHT_DEFAULT_SOUND = encodeActions({notify: true, sound: "default", highlight: true});
static ACTION_DONT_NOTIFY = encodeActions({notify: false});
static ACTION_NOTIFY = encodeActions({ notify: true });
static ACTION_NOTIFY_DEFAULT_SOUND = encodeActions({ notify: true, sound: "default" });
static ACTION_NOTIFY_RING_SOUND = encodeActions({ notify: true, sound: "ring" });
static ACTION_HIGHLIGHT = encodeActions({ notify: true, highlight: true });
static ACTION_HIGHLIGHT_DEFAULT_SOUND = encodeActions({ notify: true, sound: "default", highlight: true });
static ACTION_DONT_NOTIFY = encodeActions({ notify: false });
static ACTION_DISABLED = null;
}

View file

@ -16,9 +16,9 @@ limitations under the License.
*/
import { _td } from '../languageHandler';
import {StandardActions} from "./StandardActions";
import {PushRuleVectorState} from "./PushRuleVectorState";
import {NotificationUtils} from "./NotificationUtils";
import { StandardActions } from "./StandardActions";
import { PushRuleVectorState } from "./PushRuleVectorState";
import { NotificationUtils } from "./NotificationUtils";
class VectorPushRuleDefinition {
constructor(opts) {