@glissandoo/lib 1.16.7 → 1.16.9
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/lang/ca.json +5 -5
- package/lang/de.json +6 -6
- package/lang/es.json +5 -5
- package/lang/eu.json +6 -6
- package/lang/gl.json +5 -5
- package/lang/pt.json +5 -5
- package/models/Group/index.d.ts +4 -4
- package/models/Group/index.js +7 -5
- package/package.json +2 -1
- package/helpers/sections/index.d.ts +0 -78
- package/helpers/sections/index.js +0 -8
- package/models/FileSection/index.d.ts +0 -8
- package/models/FileSection/index.js +0 -19
- package/models/Section/index.d.ts +0 -8
- package/models/Section/index.js +0 -14
package/lang/ca.json
CHANGED
|
@@ -213,12 +213,12 @@
|
|
|
213
213
|
"practices.players.add.title": "Nous assajos",
|
|
214
214
|
"practices.players.remove.text": "Us han eliminat d'una sèrie d'assajos entre {date:event.0.datetime:shortDate} i {date:event.1.datetime:shortDate}",
|
|
215
215
|
"practices.players.remove.title": "Assajos eliminats",
|
|
216
|
-
"repertoireTags.1": "
|
|
217
|
-
"repertoireTags.2": "
|
|
218
|
-
"repertoireTags.3": "
|
|
219
|
-
"repertoireTags.4": "
|
|
216
|
+
"repertoireTags.1": "1r",
|
|
217
|
+
"repertoireTags.2": "2n",
|
|
218
|
+
"repertoireTags.3": "3r",
|
|
219
|
+
"repertoireTags.4": "4t",
|
|
220
220
|
"repertoireTags.principal": "Principal",
|
|
221
|
-
"sections.all": "
|
|
221
|
+
"sections.all": "Tots",
|
|
222
222
|
"theme.claim.new.text": "{string:user.0.displayName} ha reclamat la partitura de {instrument:extra.instrumentId} de l'obra \"{string:extra.title}\"",
|
|
223
223
|
"theme.claim.new.title": "Han demanat una partitura",
|
|
224
224
|
"theme.claim.update.text": "S'afegit la partitura de {instrument:extra.instrumentId} de l'obra \"{string:extra.title}\"",
|
package/lang/de.json
CHANGED
|
@@ -213,12 +213,12 @@
|
|
|
213
213
|
"practices.players.add.title": "Neue Proben",
|
|
214
214
|
"practices.players.remove.text": "Du wurdest aus einer Reihe von Proben von {date:event.0.datetime:shortDate} bis {date:event.1.datetime:shortDate} entfernt.",
|
|
215
215
|
"practices.players.remove.title": "Die Proben wurden entfernt",
|
|
216
|
-
"repertoireTags.1": "
|
|
217
|
-
"repertoireTags.2": "
|
|
218
|
-
"repertoireTags.3": "
|
|
219
|
-
"repertoireTags.4": "
|
|
220
|
-
"repertoireTags.principal": "
|
|
221
|
-
"sections.all": "
|
|
216
|
+
"repertoireTags.1": "1.",
|
|
217
|
+
"repertoireTags.2": "2.",
|
|
218
|
+
"repertoireTags.3": "3.",
|
|
219
|
+
"repertoireTags.4": "4.",
|
|
220
|
+
"repertoireTags.principal": "Haupt",
|
|
221
|
+
"sections.all": "Alle",
|
|
222
222
|
"theme.claim.new.text": "{string:user.0.displayName} beanspruchte die Noten \nvon {instrument:extra.instrumentld} des Stücks \"{string:extra.title}“",
|
|
223
223
|
"theme.claim.new.title": "Noten wurden angefordert",
|
|
224
224
|
"theme.claim.update.text": "{instrument:extra.instrumentld} -Noten des Stücks \"{string:extra.title}\" wurden hinzugefügt.",
|
package/lang/es.json
CHANGED
|
@@ -213,12 +213,12 @@
|
|
|
213
213
|
"practices.players.add.title": "Nuevos ensayos",
|
|
214
214
|
"practices.players.remove.text": "Has sido eliminado de una serie de ensayos entre {date:event.0.datetime:shortDate} y {date:event.1.datetime:shortDate}",
|
|
215
215
|
"practices.players.remove.title": "Ensayos eliminados",
|
|
216
|
-
"repertoireTags.1": "
|
|
217
|
-
"repertoireTags.2": "
|
|
218
|
-
"repertoireTags.3": "
|
|
219
|
-
"repertoireTags.4": "
|
|
216
|
+
"repertoireTags.1": "1º",
|
|
217
|
+
"repertoireTags.2": "2º",
|
|
218
|
+
"repertoireTags.3": "3º",
|
|
219
|
+
"repertoireTags.4": "4º",
|
|
220
220
|
"repertoireTags.principal": "Principal",
|
|
221
|
-
"sections.all": "
|
|
221
|
+
"sections.all": "Todos",
|
|
222
222
|
"theme.claim.new.text": "{string:user.0.displayName} ha reclamado la partitura de {instrument:extra.instrumentId} de la obra \"{string:extra.title}\"",
|
|
223
223
|
"theme.claim.new.title": "Han pedido una partitura",
|
|
224
224
|
"theme.claim.update.text": "Se ha añadido la partitura de {instrument:extra.instrumentId} de la obra \"{string:extra.title}\"",
|
package/lang/eu.json
CHANGED
|
@@ -213,12 +213,12 @@
|
|
|
213
213
|
"practices.players.add.title": "Entsegu berriak",
|
|
214
214
|
"practices.players.remove.text": "{date:event.0.datetime:shortDate} eta {date:event.1.datetime:shortDate} egunen arteko entsegu batzuetatik ezabatua izan zara",
|
|
215
215
|
"practices.players.remove.title": "Bertan behera utzi diren entseguak",
|
|
216
|
-
"repertoireTags.1": "
|
|
217
|
-
"repertoireTags.2": "
|
|
218
|
-
"repertoireTags.3": "
|
|
219
|
-
"repertoireTags.4": "
|
|
220
|
-
"repertoireTags.principal": "
|
|
221
|
-
"sections.all": "
|
|
216
|
+
"repertoireTags.1": "1.a",
|
|
217
|
+
"repertoireTags.2": "2.a",
|
|
218
|
+
"repertoireTags.3": "3.a",
|
|
219
|
+
"repertoireTags.4": "4.a",
|
|
220
|
+
"repertoireTags.principal": "Lehen",
|
|
221
|
+
"sections.all": "Guztiak",
|
|
222
222
|
"theme.claim.new.text": "{string:user.0.displayName} erabiltzaileak \"{string:extra.title}\" obrako {instrument:extra.instrumentId} instrumentuaren partitura eskatu du",
|
|
223
223
|
"theme.claim.new.title": "Partitura bat eskatu da",
|
|
224
224
|
"theme.claim.update.text": "{instrument:extra.instrumentId} instrumentuaren partitura gehitu da \"{string:extra.title}\" obrarako",
|
package/lang/gl.json
CHANGED
|
@@ -213,12 +213,12 @@
|
|
|
213
213
|
"practices.players.add.title": "Novas probas",
|
|
214
214
|
"practices.players.remove.text": "Elimináronte dunha serie de ensaios entre {date:event.0.datetime:shortDate} e {date:event.1.datetime:shortDate}",
|
|
215
215
|
"practices.players.remove.title": "Quitáronse os ensaios",
|
|
216
|
-
"repertoireTags.1": "
|
|
217
|
-
"repertoireTags.2": "
|
|
218
|
-
"repertoireTags.3": "
|
|
219
|
-
"repertoireTags.4": "
|
|
216
|
+
"repertoireTags.1": "1º",
|
|
217
|
+
"repertoireTags.2": "2º",
|
|
218
|
+
"repertoireTags.3": "3º",
|
|
219
|
+
"repertoireTags.4": "4º",
|
|
220
220
|
"repertoireTags.principal": "Principal",
|
|
221
|
-
"sections.all": "
|
|
221
|
+
"sections.all": "Todos",
|
|
222
222
|
"theme.claim.new.text": "{string:user.0.displayName} ha reclamado la partitura de {instrument:extra.instrument} de la obra \"{string:extra.title}\"",
|
|
223
223
|
"theme.claim.new.title": "Han pedido una partitura",
|
|
224
224
|
"theme.claim.update.text": "Se ha añadido la partitura de {instrument:extra.instrument} de la obra \"{string:extra.title}\"",
|
package/lang/pt.json
CHANGED
|
@@ -213,12 +213,12 @@
|
|
|
213
213
|
"practices.players.add.title": "Novos ensaios",
|
|
214
214
|
"practices.players.remove.text": "Você foi removido de vários ensaios entre {date:event.0.datetime:shortDate} e {date:event.1.datetime:shortDate}",
|
|
215
215
|
"practices.players.remove.title": "Ensaios removidos",
|
|
216
|
-
"repertoireTags.1": "
|
|
217
|
-
"repertoireTags.2": "
|
|
218
|
-
"repertoireTags.3": "
|
|
219
|
-
"repertoireTags.4": "
|
|
216
|
+
"repertoireTags.1": "1º",
|
|
217
|
+
"repertoireTags.2": "2º",
|
|
218
|
+
"repertoireTags.3": "3º",
|
|
219
|
+
"repertoireTags.4": "4º",
|
|
220
220
|
"repertoireTags.principal": "Principal",
|
|
221
|
-
"sections.all": "
|
|
221
|
+
"sections.all": "Todos",
|
|
222
222
|
"theme.claim.new.text": "{string:user.0.displayName} uma revisão em {instrument:extra.instrumentId} para “{string:extra.title}”",
|
|
223
223
|
"theme.claim.new.title": "Uma revisão da partitura foi enviada por um músico",
|
|
224
224
|
"theme.claim.update.text": "A partitura {instrument:extra.instrumentId} da obra “{string:extra.title}” foi adicionada.",
|
package/models/Group/index.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import { DocumentReference, DocumentSnapshot } from '@google-cloud/firestore';
|
|
|
2
2
|
import { PlansGroup } from '../../helpers/plans';
|
|
3
3
|
import { LanguagesTypes } from '../../lang';
|
|
4
4
|
import GroupBasic from './basic';
|
|
5
|
-
import { GroupData, GroupStatus, SocialNetwork } from './types';
|
|
5
|
+
import { GroupData, GroupStatus, SocialNetwork, GroupRepertoireTag } from './types';
|
|
6
6
|
export default class Group extends GroupBasic<GroupData> {
|
|
7
7
|
constructor(doc: DocumentSnapshot, lang?: LanguagesTypes);
|
|
8
8
|
get owner(): DocumentReference;
|
|
@@ -61,9 +61,9 @@ export default class Group extends GroupBasic<GroupData> {
|
|
|
61
61
|
id: string;
|
|
62
62
|
})[];
|
|
63
63
|
get firstAnswerAt(): FirebaseFirestore.Timestamp | null;
|
|
64
|
-
get repertoireTags(): Record<string,
|
|
65
|
-
get repertoireTagsList(): (
|
|
64
|
+
get repertoireTags(): Record<string, GroupRepertoireTag>;
|
|
65
|
+
get repertoireTagsList(): (GroupRepertoireTag & {
|
|
66
66
|
id: string;
|
|
67
67
|
})[];
|
|
68
|
-
|
|
68
|
+
getRepertoireTagNameTranslator(): (id: string, repertoireTags?: Record<string, GroupRepertoireTag>, lang?: LanguagesTypes) => string | null;
|
|
69
69
|
}
|
package/models/Group/index.js
CHANGED
|
@@ -168,11 +168,13 @@ class Group extends basic_1.default {
|
|
|
168
168
|
get repertoireTagsList() {
|
|
169
169
|
return utils_1.objToArray(this.repertoireTags);
|
|
170
170
|
}
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
171
|
+
getRepertoireTagNameTranslator() {
|
|
172
|
+
return (id, repertoireTags = { ...this.repertoireTags }, lang = this.lang) => {
|
|
173
|
+
if (!(id in repertoireTags))
|
|
174
|
+
return null;
|
|
175
|
+
const tag = repertoireTags[id];
|
|
176
|
+
return tag.default ? lang_1.getTranslation(tag.title, lang) : tag.title;
|
|
177
|
+
};
|
|
176
178
|
}
|
|
177
179
|
}
|
|
178
180
|
exports.default = Group;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@glissandoo/lib",
|
|
3
|
-
"version": "1.16.
|
|
3
|
+
"version": "1.16.9",
|
|
4
4
|
"description": "Glissandoo library js",
|
|
5
5
|
"main": "./index.js",
|
|
6
6
|
"types": "./index.d.ts",
|
|
@@ -12,6 +12,7 @@
|
|
|
12
12
|
"format:single": "prettier --write",
|
|
13
13
|
"lint": "eslint --ext .ts ./src",
|
|
14
14
|
"prepare": "rm -rf ./lib && npm run build",
|
|
15
|
+
"set-husky": "node scripts/setHusky.js",
|
|
15
16
|
"preversion": "npm run lint",
|
|
16
17
|
"version": "npm run format && git add -A src && ./publish.sh",
|
|
17
18
|
"postversion": "git push && git push --tags",
|
|
@@ -1,78 +0,0 @@
|
|
|
1
|
-
import { InstrumentId } from "../instruments";
|
|
2
|
-
export declare const SectionId: {
|
|
3
|
-
All: "all";
|
|
4
|
-
Accordion: InstrumentId.Accordion;
|
|
5
|
-
Bandurria: InstrumentId.Bandurria;
|
|
6
|
-
Bagpipes: InstrumentId.Bagpipes;
|
|
7
|
-
Banjo: InstrumentId.Banjo;
|
|
8
|
-
Baritone: InstrumentId.Baritone;
|
|
9
|
-
Bass: InstrumentId.Bass;
|
|
10
|
-
BassChoir: InstrumentId.BassChoir;
|
|
11
|
-
BassDrum: InstrumentId.BassDrum;
|
|
12
|
-
Bassoon: InstrumentId.Bassoon;
|
|
13
|
-
BassoonContra: InstrumentId.BassoonContra;
|
|
14
|
-
Cajon: InstrumentId.Cajon;
|
|
15
|
-
Castanets: InstrumentId.Castanets;
|
|
16
|
-
Cello: InstrumentId.Cello;
|
|
17
|
-
Choir: InstrumentId.Choir;
|
|
18
|
-
Clarinet: InstrumentId.Clarinet;
|
|
19
|
-
ClarinetAlto: InstrumentId.ClarinetAlto;
|
|
20
|
-
ClarinetBass: InstrumentId.ClarinetBass;
|
|
21
|
-
ClarinetContrabass: InstrumentId.ClarinetContrabass;
|
|
22
|
-
ClarinetLittle: InstrumentId.ClarinetLittle;
|
|
23
|
-
ContraAlto: InstrumentId.ContraAlto;
|
|
24
|
-
Cornet: InstrumentId.Cornet;
|
|
25
|
-
CounterTenor: InstrumentId.CounterTenor;
|
|
26
|
-
Cymbals: InstrumentId.Cymbals;
|
|
27
|
-
DJ: InstrumentId.DJ;
|
|
28
|
-
DoubleBass: InstrumentId.DoubleBass;
|
|
29
|
-
DrumSet: InstrumentId.DrumSet;
|
|
30
|
-
Dulzaina: InstrumentId.Dulzaina;
|
|
31
|
-
DulzainaFa: InstrumentId.DulzainaFa;
|
|
32
|
-
ElectricGuitar: InstrumentId.ElectricGuitar;
|
|
33
|
-
EnglishHorn: InstrumentId.EnglishHorn;
|
|
34
|
-
Euphonium: InstrumentId.Euphonium;
|
|
35
|
-
FlugeHorn: InstrumentId.FlugeHorn;
|
|
36
|
-
Flute: InstrumentId.Flute;
|
|
37
|
-
FluteLow: InstrumentId.FluteLow;
|
|
38
|
-
FrenchHorn: InstrumentId.FrenchHorn;
|
|
39
|
-
Guitar: InstrumentId.Guitar;
|
|
40
|
-
Harmonica: InstrumentId.Harmonica;
|
|
41
|
-
Harp: InstrumentId.Harp;
|
|
42
|
-
Keyboard: InstrumentId.Keyboard;
|
|
43
|
-
Lute: InstrumentId.Lute;
|
|
44
|
-
Mallets: InstrumentId.Mallets;
|
|
45
|
-
Mandoline: InstrumentId.Mandoline;
|
|
46
|
-
MezzoSoprano: InstrumentId.MezzoSoprano;
|
|
47
|
-
MusicConductor: InstrumentId.MusicConductor;
|
|
48
|
-
Oboe: InstrumentId.Oboe;
|
|
49
|
-
Percussion: InstrumentId.Percussion;
|
|
50
|
-
Piano: InstrumentId.Piano;
|
|
51
|
-
Piccolo: InstrumentId.Piccolo;
|
|
52
|
-
SaxAlto: InstrumentId.SaxAlto;
|
|
53
|
-
SaxBaritone: InstrumentId.SaxBaritone;
|
|
54
|
-
SaxLow: InstrumentId.SaxLow;
|
|
55
|
-
SaxSoprano: InstrumentId.SaxSoprano;
|
|
56
|
-
SaxTenor: InstrumentId.SaxTenor;
|
|
57
|
-
Silbote: InstrumentId.Silbote;
|
|
58
|
-
Singer: InstrumentId.Singer;
|
|
59
|
-
SnareDrum: InstrumentId.SnareDrum;
|
|
60
|
-
Soprano: InstrumentId.Soprano;
|
|
61
|
-
Tabal: InstrumentId.Tabal;
|
|
62
|
-
Tarota: InstrumentId.Tarota;
|
|
63
|
-
Tenor: InstrumentId.Tenor;
|
|
64
|
-
Timpani: InstrumentId.Timpani;
|
|
65
|
-
Trombone: InstrumentId.Trombone;
|
|
66
|
-
TromboneHigh: InstrumentId.TromboneHigh;
|
|
67
|
-
TromboneLow: InstrumentId.TromboneLow;
|
|
68
|
-
Trumpet: InstrumentId.Trumpet;
|
|
69
|
-
TrumpetLow: InstrumentId.TrumpetLow;
|
|
70
|
-
TrumpetPiccolo: InstrumentId.TrumpetPiccolo;
|
|
71
|
-
Tuba: InstrumentId.Tuba;
|
|
72
|
-
TubaWagnerian: InstrumentId.TubaWagnerian;
|
|
73
|
-
Txistu: InstrumentId.Txistu;
|
|
74
|
-
Ukelele: InstrumentId.Ukelele;
|
|
75
|
-
Viola: InstrumentId.Viola;
|
|
76
|
-
Violin: InstrumentId.Violin;
|
|
77
|
-
};
|
|
78
|
-
export declare type SectionIdType = typeof SectionId[keyof typeof SectionId];
|
|
@@ -1,19 +0,0 @@
|
|
|
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 lang_1 = require("../../lang");
|
|
7
|
-
const Instrument_1 = __importDefault(require("../Instrument"));
|
|
8
|
-
class Section {
|
|
9
|
-
constructor(id, lang = lang_1.defaultLocale) {
|
|
10
|
-
this.id = id;
|
|
11
|
-
this.lang = lang;
|
|
12
|
-
}
|
|
13
|
-
get name() {
|
|
14
|
-
return ((this.id === 'all'
|
|
15
|
-
? lang_1.getTranslation(`sections.all`, this.lang)
|
|
16
|
-
: new Instrument_1.default(this.id).name) || this.id);
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
exports.default = Section;
|
package/models/Section/index.js
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const lang_1 = require("../../lang");
|
|
4
|
-
class Section {
|
|
5
|
-
constructor(id, lang = lang_1.defaultLocale) {
|
|
6
|
-
this.id = id;
|
|
7
|
-
this.lang = lang;
|
|
8
|
-
}
|
|
9
|
-
get name() {
|
|
10
|
-
const translation = lang_1.getTranslation(this.id === 'all' ? `sections.all` : `instruments.${this.id}`, this.lang);
|
|
11
|
-
return translation || this.id;
|
|
12
|
-
}
|
|
13
|
-
}
|
|
14
|
-
exports.default = Section;
|