Skip to content

Commit

Permalink
1.3.4-beta.2 (#1198)
Browse files Browse the repository at this point in the history
* 📖 Fixed Beblia chapters with just one verse not importing
- Auto format VTT files with spaces
- Fixed subtitles not getting disabled
- Fixed every overlay re-rendering when a new one is presented
- Transposed stage chords will remain per show
- Fixed text align not working in StageShow
- Specific artists blocked with web search
- Option to block any artists
- Fixed a freeze in stage tab

* Fixing PDF export margin (#1189)

* ✓ OSC should now receive remote signals
- API GET show layout slide order
- Fixed error when a file in the project did not exist
- Drawer does not close when going to edit if opened on edit page

* ✓ Fixed no response with REST commands
- Scripture API remove special HTML tags
- Fixed drawer categories rename issue
- Better edit input code

* Add removable-media to snapcraft.yaml (#1195)

* ✨ UI tweaks
- Ghost backgrounds will now show for all slides before number 40
- Fixed Bible abbreviation not always added when creating a collection
- Timer select dropdown same order as timers list
- Active media filter visible with icon
- Media fit will now override any output style media fit
- Starting multiple timers at once working better
- Right click action to edit/delete
- Duplicate timers
- Output screens properly centered in select preview
- Media/filter edit value sliders
- Fixed freeze sometimes with media backgrounds
- Increased OutputShow resolution

* 🖼️ Transparency
- Show search navigate through results
- Background color order working better
- Empty overlays/templates displays full color
- Clearer overlay/template preview
- Transparency better marked
- Enable transparent slide preview
- Resolution is now only set on output level with a style

* ✓ Version update
- Updated fonts package
- Updated Norwegian language

---------

Co-authored-by: Yoël Cornamusaz <iioel64@gmail.com>
Co-authored-by: Jeremy Wong <navhaxs@hotmail.com>
  • Loading branch information
3 people authored Jan 16, 2025
1 parent fbc960f commit d1945fb
Show file tree
Hide file tree
Showing 87 changed files with 931 additions and 605 deletions.
12 changes: 6 additions & 6 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "freeshow",
"version": "1.3.4-beta.1",
"version": "1.3.4-beta.2",
"private": true,
"main": "build/electron/index.js",
"description": "Show song lyrics and more for free!",
Expand Down Expand Up @@ -175,7 +175,7 @@
"axios": "^1.7.8",
"chord-transposer": "^3.0.9",
"cross-env": "^7.0.3",
"css-fonts": "^1.0.9",
"css-fonts": "^1.0.91",
"dayjs": "^1.11.10",
"electron-store": "^8.0.1",
"electron-updater": "^6.3.1",
Expand Down
8 changes: 8 additions & 0 deletions public/global.css
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
--secondary: #f0008c;
--secondary-opacity: rgba(240, 0, 140, 0.5);
--secondary-text: #f0f0ff;
--transparent: #232530;

--hover: rgb(255 255 255 / 0.05);
--focus: rgb(255 255 255 / 0.1);
Expand Down Expand Up @@ -126,3 +127,10 @@ p {
overflow: hidden;
white-space: nowrap;
}

/* CHECKERED */

.checkered {
/* background-color: var(--transparent); */
background: repeating-conic-gradient(rgba(70, 70, 80, 0.1) 0% 25%, transparent 0% 50%) 50% / 26px 26px;
}
3 changes: 3 additions & 0 deletions public/lang/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@
"web": "Web search",
"search_web": "Search for song on the web",
"search_results": "Search results",
"block": "Block",
"more_options": "More options",
"auto_groups": "Auto assign groups",
"format_new_show": "Format text",
Expand Down Expand Up @@ -1110,13 +1111,15 @@
"lines": "Lines",
"override_with_template": "Override slide with template",
"override_scripture_with_template": "Override scripture with template",
"overrided_value": "A template might override this value",
"active_layers": "Active layers",
"window": "Window",
"active_style": "Use style",
"alert_updates": "Alert when a new update is available",
"auto_updates": "Auto updates",
"disable_labels": "Disable labels",
"group_numbers": "Group numbers",
"transparent_slides": "Transparent slide preview",
"full_colors": "High contrast group colors",
"slide_number_keys": "Play slides with number keys",
"auto_shortcut_first_letter": "Auto shortcut to first letter in text",
Expand Down
27 changes: 25 additions & 2 deletions public/lang/no.json
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@
"web": "Nettsøk",
"search_web": "Søk etter sang på nettet",
"search_results": "Søkeresultater",
"block": "Blokker",
"more_options": "Flere alternativer",
"auto_groups": "Angi grupper automatisk",
"format_new_show": "Formater tekst",
Expand Down Expand Up @@ -148,6 +149,7 @@
"overlays": "Fjern overlegg",
"audio": "Fjern lyd",
"nextTimer": "Fjern tid til neste lysbilde",
"timer": "Fjern tidtaker",
"drawing": "Fjern tegning"
},
"remove": {
Expand Down Expand Up @@ -400,6 +402,7 @@
"trigger": "Utløser",
"audio_stream": "Lydstrøm",
"transition": "Overgang",
"media_fit": "Endre medie-tilpasning",
"delete_show": "Slett show",
"delete_show_confirmation": "Er du sikker på at du vil slette",
"delete_duplicated_shows": "Slett dupliserte show",
Expand All @@ -413,6 +416,7 @@
"animate": "Animer",
"translate": "Oversetting",
"next_timer": "Tid til neste lysbilde",
"display_duration": "Varighet for visning",
"import": "Importer",
"songbeamer_import": "Songbeamer importering",
"export": "Eksporter",
Expand All @@ -422,6 +426,7 @@
"edit_event": "Rediger hendelse",
"about": "Om",
"history": "Historie",
"manage_emitters": "Administrer utsendere",
"action": "Handling",
"category_action": "Handling for kategori",
"user_data_overwrite": "Fant eksisterende data",
Expand Down Expand Up @@ -578,6 +583,7 @@
"unmute": "Slå på lyden",
"increase_volume": "Øk volum",
"decrease_volume": "Reduser volum",
"manage_subtitles": "Administrer teksting",
"toggle_time_marker": "Veksle tidsmarkører",
"add_time_marker": "Legg til tidsmarkør",
"bind_to": "Spesifikke utgangsskjermer",
Expand Down Expand Up @@ -681,8 +687,10 @@
"start_trigger": "Start utløser",
"run_action": "Kjør handling",
"toggle_action": "Veksle handling",
"emit_data": "Send data",
"send_rest_command": "Send HTTP-forespørsel",
"custom_activation": "Egendefinert aktivering",
"any": "Hvilken som helst",
"activate_on_startup": "Aktiver ved oppstart",
"activate_save": "Aktiver ved lagring",
"activate_slide_clicked": "Aktiver ved klikk på lysbilde",
Expand Down Expand Up @@ -750,6 +758,8 @@
"all_shows": "Alle show",
"all_projects": "Alle prosjekter",
"project": "Prosjekt",
"option_type": "Hva vil du eksportere?",
"option_format": "Hvilket format vil du ha?",
"include_media": "Inkluder mediefiler",
"preview": "Forhåndsvisning",
"title": "Tittel",
Expand Down Expand Up @@ -950,6 +960,7 @@
"to_event": "Tid til arrangement",
"counter": "Nedtelling",
"time": "Tid",
"hours": "Timer",
"minutes": "Minutter",
"seconds": "Sekunder",
"from": "Fra",
Expand All @@ -969,7 +980,9 @@
"type": "Type",
"digital": "Digital",
"analog": "Analog",
"seconds": "Sekunder"
"seconds": "Sekunder",
"custom": "Egendefinert",
"show_time": "Vis tid"
},
"captions": {
"info": "Klikk på URL-en for å åpne i nettleseren din hvis du ikke allerede har gjort det, eller åpne den på en annen enhet! Sørg for å gi tilgang til mikrofonen din, og bruk Google Chrome for best ytelse.",
Expand Down Expand Up @@ -1002,6 +1015,14 @@
"tip_action": "For å aktivere spesifikke lysbilder, høyreklikk et lysbilde og velg handlingen for midi inn.",
"tip_index_by_velocity": "Indeksen bestemmes av den mottatte hastigheten, fra 0."
},
"emitters": {
"emitter": "Utsender",
"tip": "Opprett maler for å enkelt sende ut spesifikke beskjeder.",
"signal": "Signal",
"message_template": "Mal for melding",
"message_templates": "Mal for meldinger",
"inputs": "Innganger"
},
"draw": {
"focus": "Fokus",
"pointer": "Peker",
Expand Down Expand Up @@ -1090,13 +1111,15 @@
"lines": "Linjer",
"override_with_template": "Overskriv lysbilde med mal",
"override_scripture_with_template": "Overskriv bibeltekst med mal",
"overrided_value": "En mal kan overstyre denne verdien",
"active_layers": "Aktive lag",
"window": "Vindu",
"active_style": "Bruk stil",
"alert_updates": "Varsle når en ny oppdatering er tilgjengelig",
"auto_updates": "Automatisk oppdatering",
"disable_labels": "Deaktiver etiketter",
"group_numbers": "Gruppenummer",
"transparent_slides": "Gjennomsiktig forhåndsvisning av lysbilde",
"full_colors": "Gruppefarger med høy kontrast",
"slide_number_keys": "Spill av lysbilder med nummer-taster",
"auto_shortcut_first_letter": "Automatisk hurtigtast til første bokstav i tekst",
Expand Down Expand Up @@ -1207,7 +1230,7 @@
},
"scripture": {
"bibles": "Bibler fra API.Bible",
"custom": "Eller importer dine egene",
"local": "Importer lokal fil",
"max_verses": "Maks vers per lysbilde",
"verse_numbers": "Versnummer",
"verses_on_individual_lines": "Vers på enkeltlinjer",
Expand Down
1 change: 1 addition & 0 deletions snap/snapcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ apps:
- audio-playback
- pulseaudio
- opengl
- removable-media
environment:
PATH: $SNAP/usr/sbin:$SNAP/usr/bin:$SNAP/sbin:$SNAP/bin:$PATH
SNAP_DESKTOP_RUNTIME: $SNAP/gnome-platform
Expand Down
8 changes: 5 additions & 3 deletions src/electron/capture/helpers/CaptureTransmitter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { OUTPUT, OUTPUT_STREAM } from "../../../types/Channels"
import { NdiSender } from "../../ndi/NdiSender"
import util from "../../ndi/vingester-util"
import { OutputHelper } from "../../output/OutputHelper"
import { toServer } from "../../servers"
import { getConnections, toServer } from "../../servers"
import { CaptureHelper } from "../CaptureHelper"
import { toApp } from "../.."

Expand Down Expand Up @@ -116,8 +116,10 @@ export class CaptureTransmitter {
break
case "server":
// const options = OutputHelper.getOutput(captureId)?.captureOptions
// phone screen size
this.sendBufferToServer(captureId, image.resize({ width: size.width / 5, height: size.height / 5, quality: "good" }))
// WIP base on receiving screen size
const outputshowConnections = getConnections("OUTPUT_STREAM")
let reduceSize = outputshowConnections > 5 ? 0.7 : outputshowConnections > 10 ? 0.5 : outputshowConnections > 20 ? 0.3 : 0.8
this.sendBufferToServer(captureId, image.resize({ width: size.width * reduceSize, height: size.height * reduceSize, quality: "good" }))
break
case "stage":
this.sendBufferToMain(captureId, image)
Expand Down
9 changes: 7 additions & 2 deletions src/electron/data/export.ts
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ function doneWritingFile(err: any, exportFolder: string, toMain: boolean = true)
// ----- PDF -----

const options: any = {
marginsType: 1,
margins: {top: 0, bottom: 0, left: 0, right: 0},
pageSize: "A4",
printBackground: true,
landscape: false,
Expand Down Expand Up @@ -257,7 +257,12 @@ export function exportProject(data: any) {

// copy files
files.forEach((path: string) => {
zip.addLocalFile(path)
try {
// file might not exist
zip.addLocalFile(path)
} catch (err) {
console.error("Could not add a file to project:", err)
}
})

// add project file
Expand Down
10 changes: 7 additions & 3 deletions src/electron/servers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ let servers: { [key in ServerName]: any } = {
OUTPUT_STREAM: { port: 5513 },
// CAM: { port: 5513 },
}
let ioServers: any = {}
let ioServers: { [key in ServerName]?: any } = {}

createServers()
function createServers() {
Expand Down Expand Up @@ -80,17 +80,21 @@ function createBridge(server: any) {
})

// SEND DATA FROM APP TO CLIENT
ioServers[server.id] = server.io
ioServers[server.id as ServerName] = server.io
ipcMain.on(server.id, (_e, msg) => {
if (msg.id) server.io.to(msg.id).emit(server.id, msg)
else server.io.emit(server.id, msg)
})
}

export function toServer(id: string, msg: any) {
export function toServer(id: ServerName, msg: any) {
ioServers[id].emit(id, msg)
}

export function getConnections(id: ServerName) {
return Object.keys(servers[id]?.connections || {}).length
}

// FUNCTIONS

function initialize(id: ServerName, socket: any) {
Expand Down
23 changes: 13 additions & 10 deletions src/electron/utils/LyricSearch.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,17 @@ export type LyricSearchResult = {
originalQuery?: string
}

const lyricsSearchCache = new Map()
export class LyricSearch {
static search = async (artist: string, title: string) => {
const results = await Promise.all([
LyricSearch.searchGenius(artist, title),
LyricSearch.searchHymnary(title),
LyricSearch.searchLetras(title),
])
return results.flat()
const cacheKey = artist + title
if (lyricsSearchCache.has(cacheKey)) return lyricsSearchCache.get(cacheKey)

const results = await Promise.all([LyricSearch.searchGenius(artist, title), LyricSearch.searchHymnary(title), LyricSearch.searchLetras(title)])
const joinedResults: LyricSearchResult[] = results.flat()

lyricsSearchCache.set(cacheKey, joinedResults)
return joinedResults
}

static get(song: LyricSearchResult) {
Expand Down Expand Up @@ -88,7 +91,7 @@ export class LyricSearch {
const url = `https://hymnary.org/text/${song.key}`
const response = await axios.get(url)
const html = await response.data
return this.getLyricFromHtml(html, /<div property=\"text\">(.*?)<\/div>/gs);
return this.getLyricFromHtml(html, /<div property=\"text\">(.*?)<\/div>/gs)
}

private static convertHymnaryToResult = (hymnaryResult: any, originalQuery: string) => {
Expand All @@ -106,7 +109,7 @@ export class LyricSearch {
try {
const url = `https://solr.sscdn.co/letras/m1/?q=${encodeURIComponent(title)}`
const response = await axios.get(url)
const json = JSON.parse(response.data.replace('LetrasSug(', '').slice(0, -2))
const json = JSON.parse(response.data.replace("LetrasSug(", "").slice(0, -2))
const songs = json.response.docs.filter((d: any) => d.id.startsWith("mus"))
return songs.map((s: any) => LyricSearch.convertLetrasToResult(s, title))
} catch (ex) {
Expand All @@ -129,7 +132,7 @@ export class LyricSearch {
const url = `https://www.letras.mus.br/${song.key}`
const response = await axios.get(url)
const html = await response.data
return this.getLyricFromHtml(html, /<div class=\"lyric-original\">(.*?)<\/div>/gs);
return this.getLyricFromHtml(html, /<div class=\"lyric-original\">(.*?)<\/div>/gs)
}

private static getLyricFromHtml = (songHtml: string, regex: RegExp) => {
Expand All @@ -152,7 +155,7 @@ export class LyricSearch {
})
result = newLines.join("\n").trim()
}
return result;
return result
}

// ref: http://stackoverflow.com/a/1293163/2343
Expand Down
Loading

0 comments on commit d1945fb

Please sign in to comment.