@glissandoo/lib 1.53.6 → 1.53.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/functions/group.d.ts +9 -1
- package/functions/groupRepertory.d.ts +1 -1
- package/functions/index.d.ts +1 -0
- package/functions/index.js +1 -0
- package/functions/regions.js +1 -0
- package/helpers/errors.d.ts +14 -1
- package/helpers/errors.js +2 -0
- package/helpers/fileSections/index.js +1 -1
- package/helpers/instruments/index.d.ts +6 -5
- package/helpers/instruments/index.js +180 -185
- package/helpers/instruments/lists.d.ts +6 -0
- package/helpers/instruments/lists.js +21 -0
- package/helpers/musicStyles/index.d.ts +2 -2
- package/helpers/musicStyles/index.js +11 -11
- package/helpers/musicStyles/orders.d.ts +3 -3
- package/helpers/musicStyles/orders.js +172 -168
- package/helpers/notifications/placeholders.js +14 -7
- package/helpers/objects.d.ts +1 -1
- package/lang/ca.json +18 -16
- package/lang/de.json +22 -20
- package/lang/en.json +18 -16
- package/lang/es.json +17 -15
- package/lang/eu.json +22 -20
- package/lang/gl.json +22 -20
- package/lang/pt.json +22 -20
- package/models/Evento/Player/basic.js +1 -1
- package/models/Group/index.d.ts +7 -2
- package/models/Group/index.js +4 -1
- package/models/Group/types.d.ts +14 -5
- package/models/Instrument/group.d.ts +12 -0
- package/models/Instrument/group.js +30 -0
- package/package.json +1 -1
package/lang/pt.json
CHANGED
|
@@ -46,14 +46,15 @@
|
|
|
46
46
|
"instruments.agogo": "Agogô",
|
|
47
47
|
"instruments.altoClarinet": "Clarinete Alto",
|
|
48
48
|
"instruments.altoSaxophone": "Saxofone alto",
|
|
49
|
+
"instruments.auxiliar": "Assistente",
|
|
49
50
|
"instruments.bagpipes": "Gaita de Foles",
|
|
50
51
|
"instruments.bandurria": "Bandurria",
|
|
51
52
|
"instruments.banjo": "Banjo",
|
|
52
53
|
"instruments.baritone": "Barítono",
|
|
53
54
|
"instruments.baritoneSax": "Saxofone barítono",
|
|
54
|
-
"instruments.bass": "Guitarra Baixo",
|
|
55
55
|
"instruments.bass-choir": "Baixo",
|
|
56
56
|
"instruments.bass-drum": "Bombo",
|
|
57
|
+
"instruments.bass": "Guitarra Baixo",
|
|
57
58
|
"instruments.bassClarinet": "Clarinete baixo",
|
|
58
59
|
"instruments.bassoon": "Fagote",
|
|
59
60
|
"instruments.cajon": "Cajon",
|
|
@@ -71,12 +72,13 @@
|
|
|
71
72
|
"instruments.dj": "DJ",
|
|
72
73
|
"instruments.doubleBass": "Contrabaixo",
|
|
73
74
|
"instruments.drumSet": "Bateria",
|
|
74
|
-
"instruments.dulzaina": "Dulzaina",
|
|
75
75
|
"instruments.dulzaina-fa": "Dulzaina F",
|
|
76
|
+
"instruments.dulzaina": "Dulzaina",
|
|
76
77
|
"instruments.electricGuitar": "Guitarra elétrica",
|
|
77
78
|
"instruments.englishHorn": "Corne Inglês",
|
|
78
79
|
"instruments.euphonium": "Eufónio",
|
|
79
80
|
"instruments.flabiol": "Flabiol",
|
|
81
|
+
"instruments.flagBearer": "Porta-estandarte",
|
|
80
82
|
"instruments.flugelhorn": "Fliscorne",
|
|
81
83
|
"instruments.flute": "Flauta",
|
|
82
84
|
"instruments.frenchHorn": "Trompa",
|
|
@@ -122,8 +124,8 @@
|
|
|
122
124
|
"instruments.timpani": "Tímpanos",
|
|
123
125
|
"instruments.trombone": "Trombone",
|
|
124
126
|
"instruments.trumpet": "Trompete",
|
|
125
|
-
"instruments.tuba": "Tuba",
|
|
126
127
|
"instruments.tuba-wagnerian": "Tuba wagneriana",
|
|
128
|
+
"instruments.tuba": "Tuba",
|
|
127
129
|
"instruments.txistu": "Txistu",
|
|
128
130
|
"instruments.ukelele": "Ukelele",
|
|
129
131
|
"instruments.viola": "viola",
|
|
@@ -139,7 +141,6 @@
|
|
|
139
141
|
"musicStyles.marching-band": "Marching Band",
|
|
140
142
|
"musicStyles.orquesta-sinfonica": "Orquestra sinfónica",
|
|
141
143
|
"musicStyles.txistularis": "Banda Txistus",
|
|
142
|
-
"performance": "Concerto",
|
|
143
144
|
"performance.assistance.confirm.byAdmin.text": "Um administrador marcou sua participação como confirmada para {string:event.0.displayName}",
|
|
144
145
|
"performance.assistance.confirm.byAdmin.title": "Presença confirmada por um administrador",
|
|
145
146
|
"performance.assistance.confirm.text": "{string:user.0.displayName} confirmou a participação em {string:event.0.displayName}",
|
|
@@ -168,10 +169,10 @@
|
|
|
168
169
|
"performance.edit.stage.title": "Concerto - o gráfico de palco mudou",
|
|
169
170
|
"performance.edit.title.text": "O título de {string:event.0.displayName} foi atualizado",
|
|
170
171
|
"performance.edit.title.title": "Concerto - o título mudou",
|
|
171
|
-
"performance.interest.confirm.text": "{string:user.0.displayName}
|
|
172
|
-
"performance.interest.confirm.title": "
|
|
173
|
-
"performance.interest.lose.text": "{string:user.0.displayName} já não está
|
|
174
|
-
"performance.interest.lose.title": "
|
|
172
|
+
"performance.interest.confirm.text": "{string:user.0.displayName} inscreveu-se para {string:event.0.displayName}",
|
|
173
|
+
"performance.interest.confirm.title": "Nova inscrição para um concerto",
|
|
174
|
+
"performance.interest.lose.text": "{string:user.0.displayName} já não está inscrito em {string:event.0.displayName}",
|
|
175
|
+
"performance.interest.lose.title": "Inscrição cancelada para o concerto",
|
|
175
176
|
"performance.players.add.text": "Você foi adicionado a {string:event.0.displayName}",
|
|
176
177
|
"performance.players.add.title": "Novo concerto",
|
|
177
178
|
"performance.players.remove.text": "Você foi removido de {string:event.0.displayName}",
|
|
@@ -188,11 +189,11 @@
|
|
|
188
189
|
"performance.reminderDeadlineSoon.pending.title": "Aviso de prazo para resposta de concerto",
|
|
189
190
|
"performance.rollCallReminder.text": "Agora é o melhor momento para fazer uma votação.",
|
|
190
191
|
"performance.rollCallReminder.title": "Você pode fazer uma votação para o ensaio",
|
|
191
|
-
"performance.selection.deselect.text": "
|
|
192
|
-
"performance.selection.deselect.title": "
|
|
192
|
+
"performance.selection.deselect.text": "Não foste selecionado para participar em {string:event.0.displayName}",
|
|
193
|
+
"performance.selection.deselect.title": "Não foste selecionado para o concerto",
|
|
193
194
|
"performance.selection.select.text": "Você foi selecionado(a) para participar de {string:event.0.displayName}",
|
|
194
195
|
"performance.selection.select.title": "Selecionado para o concerto",
|
|
195
|
-
"
|
|
196
|
+
"performance": "Concerto",
|
|
196
197
|
"practice.assistance.confirm.byAdmin.text": "Um administrador marcou sua participação como confirmada para o ensaio em {date:event.0.[datetime,timezone]:date}",
|
|
197
198
|
"practice.assistance.confirm.byAdmin.title": "Presença confirmada por um administrador",
|
|
198
199
|
"practice.assistance.confirm.text": "{string:user.0.displayName} participará do ensaio em {date:event.0.[datetime,timezone]:date}.",
|
|
@@ -221,10 +222,10 @@
|
|
|
221
222
|
"practice.edit.stage.title": "Ensaio - gráfico de palco alterado",
|
|
222
223
|
"practice.edit.title.text": "O título do ensaio {date:event.0.[datetime,timezone]:date} foi atualizado",
|
|
223
224
|
"practice.edit.title.title": "Ensaio - título alterado",
|
|
224
|
-
"practice.interest.confirm.text": "{string:user.0.displayName}
|
|
225
|
-
"practice.interest.confirm.title": "
|
|
226
|
-
"practice.interest.lose.text": "{string:user.0.displayName} já não está
|
|
227
|
-
"practice.interest.lose.title": "
|
|
225
|
+
"practice.interest.confirm.text": "{string:user.0.displayName} inscreveu-se para o ensaio de {string:group.0.displayName} o {date:event.0.[datetime,timezone]:date}",
|
|
226
|
+
"practice.interest.confirm.title": "Inscrição confirmada para o ensaio",
|
|
227
|
+
"practice.interest.lose.text": "{string:user.0.displayName} já não está inscrito no ensaio de {string:group.0.displayName} o {date:event.0.[datetime,timezone]:date}",
|
|
228
|
+
"practice.interest.lose.title": "Inscrição perdida para o ensaio",
|
|
228
229
|
"practice.players.add.text": "Você foi adicionado a {string:group.0.displayName} em {date:event.0.[datetime,timezone]:datetime}",
|
|
229
230
|
"practice.players.add.title": "Novo ensaio",
|
|
230
231
|
"practice.players.remove.text": "Você foi removido de {string:group.0.displayName} em {date:event.0.[datetime,timezone]:date}",
|
|
@@ -241,10 +242,11 @@
|
|
|
241
242
|
"practice.reminderDeadlineSoon.pending.title": "Aviso de prazo para resposta de ensaio",
|
|
242
243
|
"practice.rollCallReminder.text": "Agora é o melhor momento para fazer uma votação",
|
|
243
244
|
"practice.rollCallReminder.title": "Você pode fazer uma votação no seu último ensaio.",
|
|
244
|
-
"practice.selection.deselect.text": "
|
|
245
|
-
"practice.selection.deselect.title": "
|
|
245
|
+
"practice.selection.deselect.text": "Não foste selecionado para participar no ensaio de {string:group.0.displayName} o {date:event.0.[datetime,timezone]:date}",
|
|
246
|
+
"practice.selection.deselect.title": "Não foste selecionado para o ensaio",
|
|
246
247
|
"practice.selection.select.text": "Você foi selecionado(a) para participar do ensaio de {string:group.0.displayName} em {date:event.0.[datetime,timezone]:date}",
|
|
247
248
|
"practice.selection.select.title": "Selecionado para o ensaio",
|
|
249
|
+
"practice": "Ensaio",
|
|
248
250
|
"practices.cancel.text": "{string:extra.num} ensaios do {string:group.0.displayName} entre {date:event.0.[datetime,timezone]:shortDate} e {date:event.1.[datetime,timezone]:shortDate} foram cancelados",
|
|
249
251
|
"practices.cancel.title": "Ensaios cancelados",
|
|
250
252
|
"practices.create.text": "{string:extra.num} novos ensaios de {string:group.0.displayName} entre {date:event.0.[datetime,timezone]:shortDate} e {date:event.1.[datetime,timezone]:shortDate} foram adicionados",
|
|
@@ -275,8 +277,8 @@
|
|
|
275
277
|
"repertoireTags.4": "4º",
|
|
276
278
|
"repertoireTags.principal": "Principal",
|
|
277
279
|
"sections.all": "Todos",
|
|
278
|
-
"theme.claim.new.text": "{string:user.0.displayName} uma revisão em {instrument:extra.instrumentId} para “{string:extra.title}”",
|
|
280
|
+
"theme.claim.new.text": "{string:user.0.displayName} uma revisão em {instrument:extra.[instrumentId,customInstrumentName]} para “{string:extra.title}”",
|
|
279
281
|
"theme.claim.new.title": "Uma revisão da partitura foi enviada por um músico",
|
|
280
|
-
"theme.claim.update.text": "A partitura {instrument:extra.instrumentId} da obra “{string:extra.title}” foi adicionada.",
|
|
281
|
-
"theme.claim.update.title": "Nova partitura {instrument:extra.instrumentId} foi adicionada"
|
|
282
|
+
"theme.claim.update.text": "A partitura {instrument:extra.[instrumentId,customInstrumentName]} da obra “{string:extra.title}” foi adicionada.",
|
|
283
|
+
"theme.claim.update.title": "Nova partitura {instrument:extra.[instrumentId,customInstrumentName]} foi adicionada"
|
|
282
284
|
}
|
package/models/Group/index.d.ts
CHANGED
|
@@ -66,8 +66,13 @@ export default class Group extends GroupBasic<GroupData> {
|
|
|
66
66
|
get trialEndAt(): Date;
|
|
67
67
|
get glissandooAdminUrl(): string;
|
|
68
68
|
get createdOn(): import("./types").GroupCreatedOn;
|
|
69
|
-
get instruments(): Partial<Record<import("../../helpers/instruments").
|
|
70
|
-
get instrumentsList(): import("
|
|
69
|
+
get instruments(): Partial<Record<import("../../helpers/instruments").DefaultInstrumentId, import("./types").DefaultGroupInstrument>> & Record<`customInstrument-${string}`, import("./types").CustomGroupInstrument>;
|
|
70
|
+
get instrumentsList(): Pick<(import("./types").DefaultGroupInstrument & {
|
|
71
|
+
id: import("../../helpers/instruments").DefaultInstrumentId | `customInstrument-${string}`;
|
|
72
|
+
}) | (import("./types").CustomGroupInstrument & {
|
|
73
|
+
id: import("../../helpers/instruments").DefaultInstrumentId | `customInstrument-${string}`;
|
|
74
|
+
}), "id">[];
|
|
75
|
+
get instrumentsIds(): (import("../../helpers/instruments").DefaultInstrumentId | `customInstrument-${string}`)[];
|
|
71
76
|
get visitedDashboardAt(): Record<string, import("../../types/firestore").Timestamp>;
|
|
72
77
|
get onboardingMessages(): import("./types").GroupOnboardingMessage[];
|
|
73
78
|
}
|
package/models/Group/index.js
CHANGED
|
@@ -189,7 +189,10 @@ class Group extends basic_1.default {
|
|
|
189
189
|
return this.data.instruments || {};
|
|
190
190
|
}
|
|
191
191
|
get instrumentsList() {
|
|
192
|
-
return (0, objects_1.orderedMapToArray)(this.instruments)
|
|
192
|
+
return (0, objects_1.orderedMapToArray)(this.instruments);
|
|
193
|
+
}
|
|
194
|
+
get instrumentsIds() {
|
|
195
|
+
return this.instrumentsList.map(({ id }) => id);
|
|
193
196
|
}
|
|
194
197
|
get visitedDashboardAt() {
|
|
195
198
|
return this.data.visitedDashboardAt || null;
|
package/models/Group/types.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { CustomInstrumentId, DefaultInstrumentId } from '../../helpers/instruments';
|
|
2
2
|
import { MusicStyleType } from '../../helpers/musicStyles';
|
|
3
3
|
import { PlansGroup } from '../../helpers/plans';
|
|
4
4
|
import { DocumentReference, GeoPoint, Timestamp } from '../../types/firestore';
|
|
@@ -91,12 +91,21 @@ export interface GroupRepertoireTag {
|
|
|
91
91
|
export interface AGroupRepertoireTag extends GroupRepertoireTag {
|
|
92
92
|
id: string;
|
|
93
93
|
}
|
|
94
|
-
export interface
|
|
94
|
+
export interface DefaultGroupInstrument {
|
|
95
95
|
order: number;
|
|
96
96
|
}
|
|
97
|
-
export interface
|
|
98
|
-
|
|
97
|
+
export interface CustomGroupInstrument extends DefaultGroupInstrument {
|
|
98
|
+
icon: string;
|
|
99
|
+
name: string;
|
|
100
|
+
basedOnInstrument: DefaultInstrumentId;
|
|
99
101
|
}
|
|
102
|
+
export interface AGroupDefaultInstrument extends DefaultGroupInstrument {
|
|
103
|
+
id: DefaultInstrumentId;
|
|
104
|
+
}
|
|
105
|
+
export interface AGroupCustomInstrument extends CustomGroupInstrument {
|
|
106
|
+
id: CustomInstrumentId;
|
|
107
|
+
}
|
|
108
|
+
export type AGroupInstrument = AGroupDefaultInstrument | AGroupCustomInstrument;
|
|
100
109
|
export interface GroupData extends GroupBasicData {
|
|
101
110
|
playerIds: string[];
|
|
102
111
|
players: Record<string, PlayerBasicData>;
|
|
@@ -124,7 +133,7 @@ export interface GroupData extends GroupBasicData {
|
|
|
124
133
|
eventCount: Record<EventType, number>;
|
|
125
134
|
communicationCount: number;
|
|
126
135
|
country: string;
|
|
127
|
-
instruments: Partial<Record<
|
|
136
|
+
instruments: Partial<Record<DefaultInstrumentId, DefaultGroupInstrument>> & Record<CustomInstrumentId, CustomGroupInstrument>;
|
|
128
137
|
metadata: Record<string, string>;
|
|
129
138
|
firstAnswerAt: Timestamp | null;
|
|
130
139
|
repertoireTags: Record<string, GroupRepertoireTag>;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import Instrument from '.';
|
|
2
|
+
import { CustomInstrumentId, InstrumentId } from '../../helpers/instruments';
|
|
3
|
+
import { LanguagesTypes } from '../../lang';
|
|
4
|
+
import { GroupData } from '../Group/types';
|
|
5
|
+
export default class GroupInstrument extends Instrument {
|
|
6
|
+
private groupInstruments;
|
|
7
|
+
constructor(id: InstrumentId, lang: LanguagesTypes | undefined, groupInstruments: GroupData['instruments']);
|
|
8
|
+
static isCustom(instrumentId: InstrumentId): instrumentId is CustomInstrumentId;
|
|
9
|
+
get isCustomInstrument(): boolean;
|
|
10
|
+
get name(): string;
|
|
11
|
+
get icon(): string;
|
|
12
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const _1 = __importDefault(require("."));
|
|
7
|
+
const lang_1 = require("../../lang");
|
|
8
|
+
class GroupInstrument extends _1.default {
|
|
9
|
+
constructor(id, lang = lang_1.defaultLocale, groupInstruments) {
|
|
10
|
+
super(id, lang);
|
|
11
|
+
this.groupInstruments = groupInstruments;
|
|
12
|
+
}
|
|
13
|
+
static isCustom(instrumentId) {
|
|
14
|
+
return instrumentId.startsWith('customInstrument-');
|
|
15
|
+
}
|
|
16
|
+
get isCustomInstrument() {
|
|
17
|
+
return GroupInstrument.isCustom(this.id);
|
|
18
|
+
}
|
|
19
|
+
get name() {
|
|
20
|
+
return GroupInstrument.isCustom(this.id) && this.id in this.groupInstruments
|
|
21
|
+
? this.groupInstruments[this.id].name
|
|
22
|
+
: super.name;
|
|
23
|
+
}
|
|
24
|
+
get icon() {
|
|
25
|
+
return GroupInstrument.isCustom(this.id) && this.id in this.groupInstruments
|
|
26
|
+
? this.groupInstruments[this.id].icon
|
|
27
|
+
: super.icon;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
exports.default = GroupInstrument;
|