16 Commits

Author SHA1 Message Date
Knut Ahlers
d5cd829834 Fix: Remove password reset token after successful reset (#248)
Signed-off-by: Knut Ahlers <knut@ahlers.me>

Signed-off-by: Knut Ahlers <knut@ahlers.me>
2022-11-04 15:52:07 +01:00
Florian Weber
1109537675 Merge pull request #225 from Mejans/mnt
i18n: update Occitan locale
2022-04-28 11:47:52 +02:00
Florian Weber
a6952e877b Merge pull request #238 from medienhaus/mnt
Allow providing auth session token via HTTP header
2022-04-28 11:18:48 +02:00
Florian Weber
65282fef26 Allow providing auth session token via HTTP header 2022-04-27 13:02:57 +02:00
Mejans
8fb37f93a4 Update oc.js 2021-11-10 17:54:02 +01:00
m0ppers
aacc3a8f10 🐛 add opus-dev to Dockerfile (#218)
latest audiowaveform has a dependency on opus-dev and docker wouldn't build the image without having the library
2021-08-10 19:06:21 +02:00
Romuald
6551734ac1 Fix div positioning on Firefox and Safari issue #87 (#201)
* fix div positionning on Firefox and Safari

* Use style to fix css positionning for artifact
2021-08-10 18:04:19 +02:00
nik gaffney
ef0d085e22 docs: add email config (#191) (#210) 2021-07-13 12:12:13 +02:00
dependabot[bot]
f94f05b77a Bump ws from 3.3.1 to 5.2.3 (#209)
Bumps [ws](https://github.com/websockets/ws) from 3.3.1 to 5.2.3.
- [Release notes](https://github.com/websockets/ws/releases)
- [Commits](https://github.com/websockets/ws/compare/3.3.1...5.2.3)

---
updated-dependencies:
- dependency-name: ws
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-07-11 17:56:05 +02:00
dependabot[bot]
1504b4bff6 Bump normalize-url from 4.5.0 to 4.5.1 (#208)
Bumps [normalize-url](https://github.com/sindresorhus/normalize-url) from 4.5.0 to 4.5.1.
- [Release notes](https://github.com/sindresorhus/normalize-url/releases)
- [Commits](https://github.com/sindresorhus/normalize-url/commits)

---
updated-dependencies:
- dependency-name: normalize-url
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-07-11 17:55:57 +02:00
nblock
f94c136f26 Restore line tool (#123) 2021-07-11 17:48:22 +02:00
cynthia-rempel
6e76db7108 protect against 'ClickJacking' attacks (#197)
Sites can use this to avoid click-jacking attacks, by ensuring that their content is not embedded into other sites.
2021-07-11 17:48:00 +02:00
p-bo
0179681b9b Add Czech localization (#207) 2021-07-11 17:47:31 +02:00
1337cookie
2ff5ebe849 Empty directory to avoid errors during install. (#206) 2021-07-11 17:45:25 +02:00
mntmn
f413d0e0a3 Security Updates (#194)
* packages: automatic npm audit updates

* packages: update the rest of the packages manually

Co-authored-by: Lukas F. Hartmann <lukas@mntre.com>
2021-06-28 14:31:29 +02:00
Romuald
601211e294 fix user locale handling (#190)
* fix some french translations
add more translations
fix langage preference setup

* handle i18n for delete space or folder

* fix content layout for help text
2021-05-18 17:12:15 +02:00
22 changed files with 529 additions and 227 deletions

View File

@@ -4,7 +4,7 @@ WORKDIR /app
# build audiowaveform from source # build audiowaveform from source
RUN apk add git make cmake gcc g++ libmad-dev libid3tag-dev libsndfile-dev gd-dev boost-dev libgd libpng-dev zlib-dev RUN apk add git make cmake gcc g++ libmad-dev libid3tag-dev libsndfile-dev gd-dev boost-dev libgd libpng-dev zlib-dev opus-dev
RUN apk add zlib-static libpng-static boost-static RUN apk add zlib-static libpng-static boost-static
RUN apk add autoconf automake libtool gettext RUN apk add autoconf automake libtool gettext

32
docs/email_setup.md Normal file
View File

@@ -0,0 +1,32 @@
# Configuring Emails
There are several configuration options in `config/default.json`
## Email Relay Configuration
- mail_provider:
* `console`
* `smtp`
- mail_smtp_host:
* the IP address or FQDN of your SMTP email relay
- mail_smtp_port:
* the port used to connect to the email relay
- mail_smtp_secure: true
* whether to use TLS when connecting to the SMTP email relay
- mail_smtp_require_tls:
* `true`: attempt to use TLS even if the email relay doesn't advertise it, don't send the email if TLS isn't supported
* `false`: permits emails to be sents without using TLS
- mail_smtp_user:
* the username for the SMTP email relay.
* comment out this line for an email relay that doesn't use authentication
- mail_smtp_pass
* the password for the SMTP email relay
* comment out this line for an email relay that doesn't use authentication
## Content of Emails
- teamname:
* the team name appears on the emails sent by your spacedeck
- contact_email:
* the email address that appears on emails being sent by your spacedeck
- endpoint:
* the URL that users click on in the emails being sent by your spacedeck

332
locales/cs.js Normal file
View File

@@ -0,0 +1,332 @@
{
"ok": "OK",
"cancel": "Storno",
"close": "Zavřít",
"open": "Otevřít",
"folder": "Složka",
"save": "Uložit",
"saved": "Uloženo",
"created": "vytvořeno",
"duplicate": "Zduplikovat",
"delete": "Smazat",
"remove": "Odebrat",
"set": "nastavit",
"reset": "resetovat",
"thanks": "Díky",
"share": "Sdílet",
"signup": "Zaregistrovat se",
"login": "Přihlásit se",
"logout": "Odhlásit se",
"email": "E-mailová adresa",
"password": "Heslo",
"forgot_password": "Zapomenuté heslo",
"width": "Šířka",
"height": "Výška",
"nick": "Název",
"role": "Role",
"members": "Členové",
"actions": "Akce",
"or": "nebo",
"you": "vy",
"via": "prostřednictvím",
"by": "od",
"zero": "Nula",
"page": "Stránka",
"new": "Nevé",
"copy": "Zkopírovat",
"home": "Domů",
"owner": "Vlastník",
"space": "Prostor",
"second": "Druhé",
"not_found": "Nenalezeno.",
"untitled_space": "Prostor bez názvu",
"untitled_folder": "Složka bez názvu",
"untitled": "bez názvu",
"sure": "Opravdu to chcete?",
"specify": "Zadejte prosím",
"confirm": "Potvrďte prosím",
"error_unknown_email": "Tato kombinace e-mail/heslo není známa.",
"error_password_confirmation": "Zadání hesla se neshodují.",
"error_domain_blocked": "Doména, ze které přistupujete, je blokována.",
"error_user_email_already_used": "Tato e-mailová adresa už je používána.",
"support": "Podpora pro Spacedeck",
"offline": "Bez připojení k Internetu. Pokud chcete získat další, klikněte.",
"error": "Je nám líto, ale něco se pokazilo. Obraťte se na support@spacedeck.com",
"welcome": "Vítejte",
"claim": "Vaše digitální tabule.",
"trynow": "Vyzkoušet nyní.",
"about": "O nás",
"terms": "Všeobecné podmínky",
"contact": "Kontakt",
"privacy": "Soukromí",
"business_adress": "Adresa firmy",
"post_adress": "Poštovní adresa",
"phone": "Telefon",
"ceo": "Generální ředitel",
"name": "Název",
"confirm_subject": "Potvrzení e-mailu pro Spacedeck",
"confirm_body": "Děkujeme, že jste se zaregistrovali u Spacedeck.\nPokud chcete potvrdit svou e-mailovou adresu, klikněte na následující odkaz.\n",
"confirm_action": "Potvrdit nyní",
"team_invite_membership_subject": "Pozvánka do týmu pro %s",
"team_invite_membership_body": "Byli jste pozváni do %s na Spacedeck. Pokud chcete pozvání přijmout, klikněte na následující odkaz.",
"team_invite_user_body": "Byli jste pozvání do %s na Spacedeck.\nVaše dočasné heslo je „%s“.\nPokud chcete pozvání přijmout, klikněte na následující odkaz.",
"team_invite_admin_body": "%s byl(a) pozván(a) do vašeho týmu: %s. Dočasné heslo je „%s“.",
"team_invite_membership_acction": "Přijmout",
"team_new_member_subject": "Nový člen týmu pro %s zaregistrován",
"team_new_member_body": "%s se právě přidal k týmu %s na Spacedeck.",
"space_invite_membership_subject": "%s vás pozval(a) do prostoru %s ",
"space_invite_membership_body": "Byli jste pozvání %s, abyste se připojili do prostoru %s na Spacedeck. Pokud chcete pozvání přijmout, klikněte na následující odkaz.",
"space_invite_membership_action": "Přijmout",
"folder_invite_membership_subject": "Prostor",
"folder_invite_membership_body": "Byli jste pozvání do týmu na Spacedeck. Pokud chcete pozvání přijmout, kliněte na následující odkaz.",
"folder_invite_membership_acction": "Přijmout",
"login_google": "Přihlásit se Google účtem",
"save_changes": "Uložit změny",
"upgrade": "Přejít na vyšší variantu",
"upgrade_now": "Přejí na vyšší variantu nyní",
"create_space": "Vytvořit prostor",
"create_folder": "Vytvořit složku",
"email_unconfirmed": "E-mail nepotvrzen",
"confirmation_sent": "E-mail odeslán",
"folder_filter": "Filtrovat",
"sort_by": "Seřadit podle",
"last_modified": "Naposledy změněno",
"last_opened": "Naposledy otevřeno",
"title": "Nadpis",
"edit_team": "Upravit tým",
"edit_account": "Upravit účet",
"log_out": "Odhlásit se",
"no_spaces_yet": "Vítejte! Prostory a složky zde můžete vytvářet pomocí tlačítek v levé horním rohu.",
"new_folder_title": "Nový název složky",
"folder_settings": "Nastavení složky",
"upload_cover_image": "Nahrát obrázek pro desky",
"spacedeck_pro_ad_folders": "Se Spacedeck Pro, je možné ve složkách organizovat neomezené množství prostorů a spravovat přístup pro každou ze složek. Chcete se dozvědět víc o funkcích této vyšší varianty?",
"spacedeck_pro_ad_versions": "Se Spacedeck Pro, je možné ukládat neomezený počet verzí každého prostoru a sledovat tak svůj postup nebo si tak ukládat průběžné stavy. Chcete se dozvědět víc o funkcích této vyšší varianty?",
"spacedeck_pro_ad_pdf": "Se Spacedeck Pro, je možné exportovat vaše prostory jako PDF soubory pro účely archivace, odesílání e-mailem nebo tisk. Chcete se dozvědět víc o funkcích této vyšší varianty?",
"spacedeck_pro_ad_zip": "Se Spacedeck Pro, je možné exportovat obsah prostoru jako ZIP balíček. Chcete se dozvědět víc o funkcích této vyšší varianty?",
"spacedeck_pro_ad_colors": "Se Spacedeck Pro, je možné míchat své vlastní barvy pomocí profesionálního voliče barev.",
"profile_caption": "Profil",
"upload_avatar": "Nahrát profilový obrázek",
"uploading_avatar": "Nahrát profilový obrázek…",
"avatar_dimensions": "Doporučené rozměry: 200×200 pixelů.",
"profile_name": "Jméno",
"profile_email": "E-mailová adresa",
"send_again": "Poslat znovu",
"confirmation_sent_long": "E-mail s odkazem pro potvrzení odeslán. Podívejte se do své schránky.",
"confirmation_sent_another": "Odeslán další odkaz pro potvrzení.",
"confirmation_sent_dialog_text": "Poslali jsme vám e-mail vysvětlující jak potvrdit svou e-mailovou adresu.",
"payment_caption": "Platba",
"language_caption": "Jazyk",
"notifications_caption": "Upozornění",
"notifications_option_chat": "E-mailem mne informujte o nových komentářích",
"notifications_option_spaces": "Posílejte mi denní souhrn dění v mých prostorech a složkách",
"password_caption": "Heslo",
"current_password": "Stávající heslo",
"new_password": "Nové heslo",
"verify_password": "Ověřit si heslo",
"change_password": "Změnit si heslo",
"reset_password": "Resetovat heslo",
"terminate_caption": "Smazat účet",
"terminate_warning": "Pokud svůj účet smažete, budou veškeré prostory, složky a zprávy, včetně obsahu, který jste vy a další lidé vytvořili ve vašich prostorech ZLIKVIDOVÁNY.",
"terminate_warning2": "Toto už nepůjde napravit.",
"terminate_reason": "Zpráva",
"terminate_reason_caption": "Pomozte nám zlepšit se sdělením vašeho dúvodu pro zrušení.",
"terminate_terminate": "Ukončit",
"space_blank1": "Vítejte v novém prostoru!",
"space_blank2": "Přetáhněte sem soubory, vkládejte odkazy",
"space_blank3": "nebo použijte níže uvedené nástroje",
"space_blank4": "a zaplňte tento prostor obsahem.",
"draft": "Koncept",
"publish": "Zveřejnit",
"published": "Zveřejněno",
"save_version": "Uložit verzi",
"version_saved": "Verze uložena",
"post": "Odeslat zprávu",
"chat_invite_cta1": "Spolupráce je zábava!",
"chat_invite_cta2": "Proč ",
"chat_invite_cta3": "nepozvat nějaké lidi",
"chat_invite_cta4": "ke společné práci?",
"chat_message_placeholder": "Napiště zprávu od vás…",
"view": "Zobrazit",
"edit": "Upravit",
"present": "Přezentovat",
"chat": "Chat",
"meta": "Meta",
"tool_search": "Hledat",
"tool_upload": "Nahrát",
"tool_text": "Text",
"tool_shape": "Tvar",
"tool_zones": "Oblasti",
"tool_canvas": "Plátno",
"search_media": "Hledat média…",
"type_here": "Pište sem",
"text_formats": "Formáty",
"format_p": "Odstavec",
"format_bullets": "Seznam s odrážkami",
"format_numbers": "Číslovaný seznam",
"format_h1": "Nadpis 1",
"format_h2": "Nadpis 2",
"format_h3": "Nadpis 3",
"font_size": "Velikost písma",
"line_height": "Výška řádku",
"tool_align": "Zarovnat",
"tool_styles": "Styly",
"tool_bullets": "Odrážky",
"tool_numbers": "Čísla",
"tool_font": "Písmo",
"color_fill": "Vyplnit",
"color_stroke": "Čára",
"color_text": "Text",
"tool_type": "Typ",
"tool_box": "Box",
"tool_link": "Odkaz",
"tool_layout": "Rozvržení",
"tool_options": "Předvolby",
"tool_stroke": "Čára",
"tool_delete": "Smazat",
"tool_lock": "Uzamknout",
"tool_copy": "Zkopírovat",
"stack": "Na sebe",
"tool_circle": "Kruh",
"tool_hexagon": "Šestiúhelník",
"tool_square": "Čtverec",
"tool_diamond": "Diamant",
"tool_bubble": "Bublina",
"tool_cloud": "Mrak",
"tool_burst": "Dávka",
"tool_star": "Hvězda",
"tool_heart": "Srdce",
"tool_scribble": "Kreslení",
"tool_line": "Čára",
"tool_arrow": "Šipka",
"search_media_placeholder": "HLedat webová média…",
"add_zone": "Nová oblast",
"palette": "Paleta",
"picker": "Volič",
"background_image_caption": "Obrázek",
"background_color_caption": "Barva",
"upload_background_caption": "Obrázek pro pozadí nahrajete kliknutím",
"upload_background": "Nahrát pozadí",
"access_caption": "Přístup",
"versions_caption": "Verze",
"info_caption": "Informace",
"mode_private": "Soukromé: Upravovat mohou pouze členové",
"mode_public": "Veřejné: Zobrazit si může kdokoli, kdo má odkaz",
"invite_collaborators": "Pozvat spolupracovníky",
"revoke_access": "Zrušit přístup",
"invite": "Odeslat pozvánky",
"invitee_email_address": "E-mailová adresa nového člena",
"optional_message": "Volitelná zpráva",
"role_viewer": "Prohlížející si",
"role_editor": "Editor",
"role_admin": "Správce",
"new_space_title": "Nový název pro prostor",
"team": "Tým",
"search": "Hledat",
"search_no_results": "nic nenalezeno",
"search_clear": "vyčistit hledání",
"rename": "přejmenovat",
"mobile": "mobilní",
"image": "obrázek",
"tool_filter": "filtrovat",
"canel": "kanál",
"invite_membership_action": "akce pozvání člena",
"viewer": "prohlížející si",
"editor": "editor",
"admin": "správce",
"logging_in": "přihlašování se",
"password_confirmation": "Potvrzení hesla",
"confirm_again": "Poslali jsme vám e-mail vysvětlující jak potvrdit svou e-mailovou adresu.",
"confirmed": "Váš účet byl úspěšně potvrzen. Děkujeme.",
"signing_up": "Registrace",
"password_check_inbox": "Podívejte se do své schránky",
"new_space": "Nový prostor",
"tool_more": "Více",
"what_is_your_name": "Vítejte v %s! Zvolte si uživatelské jméno.",
"lang": "cs",
"landing_title": "Vaše tabule na webu.",
"landing_claim": "Spacedeck umožňuje snadno kombinovat všechny možné druhy virtuálních tabulí: textové poznámky, fotky, webové odkazy, dokonce video a zvukové nahrávky. ",
"landing_example": "Lidé Spacedeck používají pro uspořádávání si svých nápadů, v týmech pro zobrazení přehledu projektů, nebo na školách a univerzitách pro pestřejší, propojené zážitky z učení se.",
"spaces": "Mé prostory",
"access_editor_link": "Odkaz pro okamžité upravování",
"access_editor_link_desc": "Tento odkaz pošlete komukoli, kdo by měl být schopen tento prostor okamžitě upravovat, není zapotřebí žádný účet: ",
"access_editor_link_desc_slug": "Tento odkaz obsahuje také název prostoru. ",
"access_anonymous_edit_blocking": "Anonymní editoři mohou měnit pouze své vlastní položky",
"access_current_members": "Stávající členové",
"access_new_members": "Pozvat nové členy",
"access_no_members": "Členové tohoto prostoru se zobrazí zde.",
"comments": "komentáře",
"landing_customers": "Oblíbené u tisíců dalších uživatelů.",
"landing_features_title": "Snadno použitelné.",
"landing_features_text": "Nový Spacedeck 5 má zjednodušené, hezké uživatelské rozhraní, které usnadňuje a zpříjemňuje práci ještě více, než předtím a přitom poskytuje ještě výkonnější funkce:",
"landing_features_1": "<b>Přetahujte sem</b> obrázky, videa a zvukové soubory ze svého počítače nebo webu",
"landing_features_2": "<b>Pište a formátujte text</b>t s úplnou kontrolou nad písmy, barvami a styly",
"landing_features_3": "<b>Kreslete, opatřujte poznámkami a zvýrazňujte</b> pomocí poskytovaných grafických tvarů",
"landing_features_4": "Udělejte ze své tabule <b>přezentaci s přibližováním</b>",
"landing_features_5": "<b>Spolupracujte a chatujte</b> v reálném čase s členy týmu, studenty nebo přáteli.",
"landing_features_6": "<b>Sdílejte prostory</b> prostřednictvím webu nebo e-mailu",
"landing_features_7": "<b>Exportujte svou práci</b> jako tisknutelné PDF nebo ZIP",
"landing_pricing": "Velmi levné.",
"landing_pricing_lite": "Zdarma / osobní použití",
"landing_pricing_lite_text": "Základní verze pro shromažďování obrázků a uchovávání poznámek.",
"landing_pricing_pro_features_list": "<ul><li>Neomezené prostory</li><li>Složky</li><li>Export do PDF a ZIP</li><li>Bez vodoznaků</li><li>Uživatelsky určená pozadí</li><li>Historie aktivit</li><li>20 GB úložiště</li><ul>",
"landing_pricing_pro": "4,90 € za uživatele a měsíc. <br><small>nebo 49,90 € za uživatele a rok</small>",
"landing_pricing_pro_text": "Nabité všemy schopnostmi, které očekáváte.",
"landing_pricing_pro_features": "Nabité všemy schopnostmi, které očekáváte.",
"welcome_subject": "Vítejte ve Spacedeck",
"welcome_body": "Zdravíme!\nDěkujeme, že jste se zaregistrovali ha Spacedeck.<br>Douváme, že se vám práce v prostorech bude líbit.<br>Pamatujte, že váš účet obsahuje neomezený počet spolupracovníků. Klidně sdílejte své prostory přátelům a kolegům po celém světě.",
"invite_emails": "E-mailové adresy (oddělované čárkou)",
"history_recently_updated": "Nedávno aktualizováno",
"history_recently_empty": "Doposud se nic nestalo.",
"parent_folder": "nadřazená složka",
"created_by": "Vytvořil(a)",
"last_updated": "Naposledy aktualizováno",
"feedback_sent": "Děkujeme za zpětnou vazbu!",
"role_member": "Člen",
"team_invite_membership_action": "Přijmout pozvání",
"space_message_subject": "Nová zpráva v prostoru %s",
"space_message_body": "%s napsal(a) v %s: \n",
"pro_ad_history_headline": "Pokud přejdete na Spacedeck Pro, uvidíte zde historii nedávných aktualizací napříš všemi vašimi (sdílenými) prostory.",
"password_reset_subject": "Reset Password for Spacedeck",
"password_reset_body": "Vyžádali jste si resetování vašeho hesla do Spacedeck.\nPokud chcete nastavit nové heslo, klikněte na následující odkaz.",
"password_reset_action": "Resetovat nyní",
"was_offline": "Spojení se Spacedeck bylo přerušeno. Pokud máte neuloženou práci, ponechte tento panel prohlížeče otevřený dokud nebude spojení znovu navázáno, pak znovu proveďte jakoukoli operaci na doposud neuložených objektech.",
"subscription_failed_user_subject": "Problém s vaší platbou za Spacedeck",
"subscription_failed_user_body": "Je nám líto, nepodařilo se nám zpracovat vaší platební metodu. V nastavení svého účtu můžete snadno vytvořit novou, včetně PayPal.",
"subscription_failed_team_subject": "Problém s vaší platbou za Spacedeck",
"subscription_failed_team_body": "Je nám líto, ale nepodařilo se zpracovat platební metodu pro váš týmový účet. Prosíme opravte svou platební metodu co možná nejdříve.",
"team_name": "Název týmu",
"subdomain": "Dílčí doména",
"team_adresses": "E-mailová adresa",
"add": "Přidat",
"invited": "pozván(a)",
"duplicate_destination": "Do které složky chcete tento prostor zduplikovat?",
"duplicate_confirm": "Zduplikovat %s do %s?",
"duplicate_success": "%s bylo zduplikováno do %s.",
"goto_space": "Přejít na prostor %s",
"goto_folder": "Přejít do složky %s",
"stay_here": "Zůstat zde",
"sharing": "Sdílení",
"list": "Exportovat seznam",
"link": "Odkaz",
"download_space": "Stáhnout si prostor",
"download_as_pdf": "Stáhnout si prostor jako PDF",
"type": "Typ",
"download": "Stáhnout si",
"Previous Zone": "Předchozí oblast",
"Next Zone": "Následující oblast",
"promote": "Povýšit",
"demote": "Degradovat",
"more": "Další",
"lock": "Zamknout",
"unlock": "Odemknout",
"follow_present": "Sledovat",
"mute_present": "Nesledovat",
"follow_present_help": "Pokud tento prostor přezentuje někdo další, ostatní členové automaticky sledují prezentaci. Tímto tlačítkem se toto sledování zapíná a vypíná.",
"export": "Export",
"media": "Média",
"tool_edit_text": "Upravit text",
"tool_space_help_part_one": "Pokud chcete přidat obsah, použijte lištu s nástroji.",
"tool_space_help_part_two": "Je možné sem přetáhnout také obrázky, zvukové a video soubory.",
"tool_delete_space": "Opravdu smazat „%s“?"
}

View File

@@ -19,6 +19,7 @@
"logout": "Log out", "logout": "Log out",
"email": "Email Address", "email": "Email Address",
"password": "Password", "password": "Password",
"forgot_password": "Forgot Password",
"width": "Width", "width": "Width",
"height": "Height", "height": "Height",
"nick": "Name", "nick": "Name",
@@ -324,5 +325,8 @@
"follow_present_help": "If someone else is presenting this Space, the other members automatically follow the presentation. Switch following on or off with this button.", "follow_present_help": "If someone else is presenting this Space, the other members automatically follow the presentation. Switch following on or off with this button.",
"export": "Export", "export": "Export",
"media": "Media", "media": "Media",
"tool_edit_text": "Edit Text" "tool_edit_text": "Edit Text",
"tool_space_help_part_one": "Use the toolbar to add content.",
"tool_space_help_part_two": "You can also drop images or sound and video files.",
"tool_delete_space": "Really delete \"%s\"?"
} }

View File

@@ -20,6 +20,7 @@
"logout": "Se déconnecter", "logout": "Se déconnecter",
"email": "Adresse email", "email": "Adresse email",
"password": "Mot de passe", "password": "Mot de passe",
"forgot_password": "Mot de passe oublié",
"width": "Largeur", "width": "Largeur",
"height": "Hauteur", "height": "Hauteur",
"nick": "Nom", "nick": "Nom",
@@ -39,9 +40,9 @@
"space": "Espace", "space": "Espace",
"second": "Seconde", "second": "Seconde",
"not_found": "Pas trouvé.", "not_found": "Pas trouvé.",
"untitled": "sans titre",
"untitled_space": "Espace sans titre", "untitled_space": "Espace sans titre",
"untitled_folder": "Dossier sans titre", "untitled_folder": "Dossier sans titre",
"untitled": "sans titre",
"sure": "Êtes-vous sûr ?", "sure": "Êtes-vous sûr ?",
"specify": "Veuillez préciser :", "specify": "Veuillez préciser :",
"confirm": "Veuillez confirmer", "confirm": "Veuillez confirmer",
@@ -49,7 +50,7 @@
"error_unknown_email": "Combinaison inconnue de l'email et mot de passe.", "error_unknown_email": "Combinaison inconnue de l'email et mot de passe.",
"error_password_confirmation": "Les deux mots de passe ne correspondent pas.", "error_password_confirmation": "Les deux mots de passe ne correspondent pas.",
"error_domain_blocked": "Ce domaine a été désactivé.", "error_domain_blocked": "Ce domaine a été désactivé.",
"error_user_email_already_used": "Cette adresse email est déjà enregistré.", "error_user_email_already_used": "Cette adresse email est déjà enregistrée.",
"support": "Aide Spacedeck", "support": "Aide Spacedeck",
"offline": "Désolé, mais les serveurs Spacedeck ne peuvent pas être atteint pour le moment. Plus d' informations ici.", "offline": "Désolé, mais les serveurs Spacedeck ne peuvent pas être atteint pour le moment. Plus d' informations ici.",
"error": "Désolé, une erreur s'est produite. Veuillez contacter support@spacedeck.com", "error": "Désolé, une erreur s'est produite. Veuillez contacter support@spacedeck.com",
@@ -57,12 +58,12 @@
"claim": "Le tableau blanc partagé pour tout le monde", "claim": "Le tableau blanc partagé pour tout le monde",
"trynow": "Essayez-le gratuitement", "trynow": "Essayez-le gratuitement",
"about": "de nous", "about": "de nous",
"terms": "termes", "terms": "Termes",
"contact": "contact", "contact": "Contact",
"privacy": "sphère privée", "privacy": "Sphère privée",
"business_adress": "Siège social", "business_adress": "Siège social",
"post_adress": "Adresse courrier", "post_adress": "Adresse courrier",
"phone": "téléphone", "phone": "Téléphone",
"ceo": "Gestionnaire", "ceo": "Gestionnaire",
"name": "name", "name": "name",
"confirm_subject": "Confirmation de l'email Spacedeck", "confirm_subject": "Confirmation de l'email Spacedeck",
@@ -75,11 +76,10 @@
"team_invite_membership_acction": "Accept", "team_invite_membership_acction": "Accept",
"team_new_member_subject": "New Team Member", "team_new_member_subject": "New Team Member",
"team_new_member_body": "%s just joined Team %s on Spacedeck.", "team_new_member_body": "%s just joined Team %s on Spacedeck.",
"invite_emails": "Entrer les adresses email (séparées pas des virgules)",
"optional_message": "Message personnel (facultatif)", "optional_message": "Message personnel (facultatif)",
"space_invite_membership_subject": "Invitation Espace par %s: %s", "space_invite_membership_subject": "Invitation Espace par %s: %s",
"space_invite_membership_body": "Vous avez été invité par %s à Espace \"%s\"", "space_invite_membership_body": "Vous avez été invité par %s à Espace \"%s\"",
"space_invite_membership_action": "Accepter L'invitation", "space_invite_membership_action": "Accepter l'invitation",
"folder_invite_membership_subject": "Space", "folder_invite_membership_subject": "Space",
"folder_invite_membership_body": "You have been invited to a Team on Spacedeck. Please click on the following link to accept the invitation.", "folder_invite_membership_body": "You have been invited to a Team on Spacedeck. Please click on the following link to accept the invitation.",
"folder_invite_membership_acction": "Accept", "folder_invite_membership_acction": "Accept",
@@ -99,7 +99,7 @@
"edit_team": "Modifier l'équipe", "edit_team": "Modifier l'équipe",
"edit_account": "Modifier le compte", "edit_account": "Modifier le compte",
"log_out": "Déconnecter", "log_out": "Déconnecter",
"no_spaces_yet": "Vous ne avez pas encore créé d'espaces.", "no_spaces_yet": "Vous n'avez pas encore créé d'espace.",
"new_folder_title": "Nouveau titre pour le dossier", "new_folder_title": "Nouveau titre pour le dossier",
"folder_settings": "Paramètres du dossier", "folder_settings": "Paramètres du dossier",
"upload_cover_image": "Charger image de couverture", "upload_cover_image": "Charger image de couverture",
@@ -109,10 +109,10 @@
"spacedeck_pro_ad_zip": "Avec Spacedeck Pro, vous pouvez exporter le contenu d'un espace comme un paquet ZIP. Voulez-vous en savoir plus sur les fonctionnalités Pro?", "spacedeck_pro_ad_zip": "Avec Spacedeck Pro, vous pouvez exporter le contenu d'un espace comme un paquet ZIP. Voulez-vous en savoir plus sur les fonctionnalités Pro?",
"spacedeck_pro_ad_colors": "Avec Spacedeck Pro, vous pouvez mélanger vos propres couleurs en utilisant un sélecteur de couleur professionnelle.", "spacedeck_pro_ad_colors": "Avec Spacedeck Pro, vous pouvez mélanger vos propres couleurs en utilisant un sélecteur de couleur professionnelle.",
"profile_caption": "Profil", "profile_caption": "Profil",
"upload_avatar": "Télécharger l'image profil", "upload_avatar": "Télécharger l'image de profil",
"uploading_avatar": "L'image de profil est téléchargée…", "uploading_avatar": "L'image de profil est téléchargée…",
"avatar_dimensions": "Format suggéré: 200×200 pixels.", "avatar_dimensions": "Format suggéré: 200×200 pixels.",
"profile_name": "Name", "profile_name": "Nom",
"profile_email": "Email", "profile_email": "Email",
"send_again": "Renvoyer", "send_again": "Renvoyer",
"confirmation_sent_long": "Lien de confirmation email envoyé. Se il vous plaît vérifier votre courrier.", "confirmation_sent_long": "Lien de confirmation email envoyé. Se il vous plaît vérifier votre courrier.",
@@ -126,7 +126,7 @@
"password_caption": "Mot de passe", "password_caption": "Mot de passe",
"current_password": "Ancien mot de passe", "current_password": "Ancien mot de passe",
"new_password": "Nouveau mot de passe", "new_password": "Nouveau mot de passe",
"verify_password": "Répéter mot de passe", "verify_password": "Répéter le mot de passe",
"change_password": "Enregistrer", "change_password": "Enregistrer",
"reset_password": "Mot de passe oublié ?", "reset_password": "Mot de passe oublié ?",
"terminate_caption": "Supprimer le compte", "terminate_caption": "Supprimer le compte",
@@ -208,7 +208,7 @@
"picker": "Mélange", "picker": "Mélange",
"background_image_caption": "Image", "background_image_caption": "Image",
"background_color_caption": "Couleur", "background_color_caption": "Couleur",
"upload_background_caption": "Cliquez ici pour télécharger une image de fond.", "upload_background_caption": "Cliquer ici pour télécharger une image de fond.",
"upload_background": "Télécharger", "upload_background": "Télécharger",
"access_caption": "Accès", "access_caption": "Accès",
"versions_caption": "Versions", "versions_caption": "Versions",
@@ -222,7 +222,7 @@
"role_editor": "Éditeur", "role_editor": "Éditeur",
"role_admin": "Administrateur", "role_admin": "Administrateur",
"new_space_title": "Nouveau titre pour l'espace", "new_space_title": "Nouveau titre pour l'espace",
"invitee_email_address": "Adresse e-mail de invitee", "invitee_email_address": "Adresse e-mail de l'invité",
"viewer": "Spectateur", "viewer": "Spectateur",
"editor": "Éditeur", "editor": "Éditeur",
"admin": "Administrateur", "admin": "Administrateur",
@@ -237,7 +237,8 @@
"logging_in": "Connexion", "logging_in": "Connexion",
"password_confirmation": "Confirmation du mot de passe", "password_confirmation": "Confirmation du mot de passe",
"confirm_again": "Veuillez consulter votre boîte pour confirmer votre email.", "confirm_again": "Veuillez consulter votre boîte pour confirmer votre email.",
"confirmed": "Adresse email confirmée avec succès. merci!", "confirmed": "Adresse email confirmée avec succès. Merci !",
"signing_up": "Signing Up",
"password_check_inbox": "password_check_inbox", "password_check_inbox": "password_check_inbox",
"what_is_your_name": "Bonjour ! Choisir un nom d'utilisateur s'il vous plaît.", "what_is_your_name": "Bonjour ! Choisir un nom d'utilisateur s'il vous plaît.",
"landing_title": "Le tableau blanc partagé pour tout le monde.", "landing_title": "Le tableau blanc partagé pour tout le monde.",
@@ -271,16 +272,16 @@
"landing_pricing_pro_features": "Avec toute la puissance que vous attendez.", "landing_pricing_pro_features": "Avec toute la puissance que vous attendez.",
"welcome_subject": "Bienvenue sur Spacedeck", "welcome_subject": "Bienvenue sur Spacedeck",
"welcome_body": "Merci pour votre inscription à Spacedeck.\nNous espérons que vous aurez plaisir à travailler dans les Espaces. <br> Rappelez-vous que votre compte comprend un nombre illimité de collaborateurs. <br> N''hésitez pas à partager vos espaces avec des amis et collègues du monde entier.", "welcome_body": "Merci pour votre inscription à Spacedeck.\nNous espérons que vous aurez plaisir à travailler dans les Espaces. <br> Rappelez-vous que votre compte comprend un nombre illimité de collaborateurs. <br> N''hésitez pas à partager vos espaces avec des amis et collègues du monde entier.",
"invite_emails": "Entrer les adresses email (séparées pas des virgules)",
"history_recently_updated": "Nouvelles",
"history_recently_empty": "Rien ne se passe",
"parent_folder": "Dossier origine", "parent_folder": "Dossier origine",
"created_by": "Créé par", "created_by": "Créé par",
"last_updated": "Mis à jour", "last_updated": "Mis à jour",
"history_recently_updated": "Nouvelles",
"history_recently_empty": "Rien ne se passe",
"signing_up": "Signing Up",
"feedback_sent": "Merci pour votre commentaire !", "feedback_sent": "Merci pour votre commentaire !",
"role_member": "role_member",
"space_message_subject": "A posté sur %s", "space_message_subject": "A posté sur %s",
"space_message_body": "%s a commenté dans %s:\n", "space_message_body": "%s a commenté dans %s:\n",
"role_member": "role_member",
"password_reset_subject": "Réinitialiser le Mot de passe pour Spacedeck", "password_reset_subject": "Réinitialiser le Mot de passe pour Spacedeck",
"password_reset_body": "Salut !<br><br>Vous avez demandé la réinitialisation de votre Mot de passe.<br>Veuillez cliquer sur le lien suivant pour définir un nouveau Mot de passe.<br>", "password_reset_body": "Salut !<br><br>Vous avez demandé la réinitialisation de votre Mot de passe.<br>Veuillez cliquer sur le lien suivant pour définir un nouveau Mot de passe.<br>",
"password_reset_action": "Définir un nouveau Mot de passe", "password_reset_action": "Définir un nouveau Mot de passe",
@@ -301,21 +302,26 @@
"goto_space": "Aller à l'espace %s", "goto_space": "Aller à l'espace %s",
"goto_folder": "Aller au dossier %s", "goto_folder": "Aller au dossier %s",
"stay_here": "Reste ici", "stay_here": "Reste ici",
"download_space": "télécharger un espace", "sharing": "Partager",
"download_as_pdf": "télécharger un espace comme PDF", "list": "Exporter la liste",
"link": "Link",
"download_space": "Télécharger un espace",
"download_as_pdf": "Télécharger un espace comme PDF",
"type": "Type", "type": "Type",
"download": "Télécharger",
"Previous Zone": "Zone précédent", "Previous Zone": "Zone précédent",
"Next Zone": "Zone suivante", "Next Zone": "Zone suivante",
"list": "liste", "promote": "Promouvoir",
"promote": "promouvoir", "demote": "Rétrograder",
"demote": "rétrograder", "lock": "Bloquer",
"lock": "bloquer", "unlock": "Déverrouiller",
"unlock": "déverrouillage",
"link": "link",
"download": "download",
"more": "plus", "more": "plus",
"follow_present": "Suivre", "follow_present": "Suivre",
"mute_present": "Pas suivre", "mute_present": "Pas suivre",
"follow_present_help": "follow_present_help", "follow_present_help": "follow_present_help",
"media": "Media" "media": "Media",
"tool_edit_text": "Modifier le texte",
"tool_space_help_part_one": "Utilisez la barre d'outil pour ajouter des éléments.",
"tool_space_help_part_two": "Vous pouvez également déposer des fichiers images, son ou video.",
"tool_delete_space": "Confirmez-vous la suppression de \"%s\" ?"
} }

View File

@@ -19,6 +19,7 @@
"logout": "Se desconnectar", "logout": "Se desconnectar",
"email": "Adreça electronica", "email": "Adreça electronica",
"password": "Senhal", "password": "Senhal",
"forgot_password": "Senhal oblidat",
"width": "Largor", "width": "Largor",
"height": "Nautor", "height": "Nautor",
"nick": "Escais", "nick": "Escais",
@@ -323,5 +324,9 @@
"mute_present": "Quitar de seguir", "mute_present": "Quitar de seguir",
"follow_present_help": "Se qualquun mai presenta aqueste espaci, los demai membres seguiràn automaticament la presentacion. Basculatz labonament a la presentacion amb aqueste boton.", "follow_present_help": "Se qualquun mai presenta aqueste espaci, los demai membres seguiràn automaticament la presentacion. Basculatz labonament a la presentacion amb aqueste boton.",
"export": "exportar", "export": "exportar",
"media": "Mèdia" "media": "Mèdia",
"tool_edit_text": "Editar tèxt",
"tool_space_help_part_one": "Utilizar la barra daisina per apondre de contengut.",
"tool_space_help_part_two": "Podètz tanben lisar dimatges o de fichièrs sons o vidèos.",
"tool_delete_space": "Suprimir « %s » per de bon ?"
} }

View File

@@ -23,7 +23,12 @@ module.exports = (req, res, next) => {
} }
// authentication via session/cookie // authentication via session/cookie
const token = req.cookies["sdsession"]; let token = req.cookies["sdsession"];
if (!token || token == null) {
// authentication via session/header
token = req.headers["x-spacedeck-auth"];
}
if (token && token != "null" && token != null) { if (token && token != "null" && token != null) {
db.Session.findOne({ where: { token: token } }) db.Session.findOne({ where: { token: token } })

41
package-lock.json generated
View File

@@ -1035,14 +1035,6 @@
"supports-color": "^5.3.0" "supports-color": "^5.3.0"
} }
}, },
"chargebee": {
"version": "2.6.5",
"resolved": "https://registry.npmjs.org/chargebee/-/chargebee-2.6.5.tgz",
"integrity": "sha512-h11cxGXN+6I47F0Ncj7pemnYO05kLm/vOKPK9mcvdU6K/HByNI/ArlvOLLhpFqjrePfTyCmBTqDYWgYjMP3uJg==",
"requires": {
"q": ">=1.0.1"
}
},
"cheerio": { "cheerio": {
"version": "0.22.0", "version": "0.22.0",
"resolved": "https://registry.npmjs.org/cheerio/-/cheerio-0.22.0.tgz", "resolved": "https://registry.npmjs.org/cheerio/-/cheerio-0.22.0.tgz",
@@ -4663,9 +4655,9 @@
} }
}, },
"normalize-url": { "normalize-url": {
"version": "4.5.0", "version": "4.5.1",
"resolved": "https://registry.npmjs.org/normalize-url/-/normalize-url-4.5.0.tgz", "resolved": "https://registry.npmjs.org/normalize-url/-/normalize-url-4.5.1.tgz",
"integrity": "sha512-2s47yzUxdexf1OhyRi4Em83iQk0aPvwTddtFz4hnSSw9dCEsLEGf6SwIO8ss/19S9iBb5sJaOuTvTGDeZI00BQ==", "integrity": "sha512-9UZCFRHQdNrfTpGg8+1INIg93B6zE0aXMVFkw1WFwvO4SlZywU6aLg5Of0Ap/PgcbSw4LNxvMWXMeugwMCX0AA==",
"dev": true "dev": true
}, },
"now-and-later": { "now-and-later": {
@@ -5275,11 +5267,6 @@
} }
} }
}, },
"q": {
"version": "1.5.1",
"resolved": "https://registry.npmjs.org/q/-/q-1.5.1.tgz",
"integrity": "sha1-fjL3W0E4EpHQRhHxvxQQmsAGUdc="
},
"qs": { "qs": {
"version": "6.7.0", "version": "6.7.0",
"resolved": "https://registry.npmjs.org/qs/-/qs-6.7.0.tgz", "resolved": "https://registry.npmjs.org/qs/-/qs-6.7.0.tgz",
@@ -6871,11 +6858,6 @@
"is-typedarray": "^1.0.0" "is-typedarray": "^1.0.0"
} }
}, },
"ultron": {
"version": "1.1.1",
"resolved": "https://registry.npmjs.org/ultron/-/ultron-1.1.1.tgz",
"integrity": "sha512-UIEXBNeYmKptWH6z8ZnqTeS8fV74zG0/eRU9VGkpzz+LIJNs8W/zM/L+7ctCkRrgbNnnR0xxw4bKOr0cW0N0Og=="
},
"umzug": { "umzug": {
"version": "2.3.0", "version": "2.3.0",
"resolved": "https://registry.npmjs.org/umzug/-/umzug-2.3.0.tgz", "resolved": "https://registry.npmjs.org/umzug/-/umzug-2.3.0.tgz",
@@ -7414,20 +7396,11 @@
} }
}, },
"ws": { "ws": {
"version": "3.3.1", "version": "5.2.3",
"resolved": "https://registry.npmjs.org/ws/-/ws-3.3.1.tgz", "resolved": "https://registry.npmjs.org/ws/-/ws-5.2.3.tgz",
"integrity": "sha512-8A/uRMnQy8KCQsmep1m7Bk+z/+LIkeF7w+TDMLtX1iZm5Hq9HsUDmgFGaW1ACW5Cj0b2Qo7wCvRhYN2ErUVp/A==", "integrity": "sha512-jZArVERrMsKUatIdnLzqvcfydI85dvd/Fp1u/VOpfdDWQ4c9qWXe+VIeAbQ5FrDwciAkr+lzofXLz3Kuf26AOA==",
"requires": { "requires": {
"async-limiter": "~1.0.0", "async-limiter": "~1.0.0"
"safe-buffer": "~5.1.0",
"ultron": "~1.1.0"
},
"dependencies": {
"safe-buffer": {
"version": "5.1.2",
"resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz",
"integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g=="
}
} }
}, },
"x-xss-protection": { "x-xss-protection": {

View File

@@ -15,7 +15,6 @@
"async": "2.3.0", "async": "2.3.0",
"bcryptjs": "2.4.3", "bcryptjs": "2.4.3",
"body-parser": "^1.19.0", "body-parser": "^1.19.0",
"chargebee": "2.6.5",
"cheerio": "0.22.0", "cheerio": "0.22.0",
"config": "1.25.1", "config": "1.25.1",
"cookie-parser": "~1.4.3", "cookie-parser": "~1.4.3",
@@ -45,7 +44,7 @@
"underscore": "^1.13.1", "underscore": "^1.13.1",
"uuid": "^3.2.1", "uuid": "^3.2.1",
"validator": "7.0.0", "validator": "7.0.0",
"ws": "3.3.1" "ws": "5.2.3"
}, },
"devDependencies": { "devDependencies": {
"gulp": "^4.0.2", "gulp": "^4.0.2",

View File

@@ -487,7 +487,7 @@ var SpacedeckSpaces = {
}, },
delete_space: function(space) { delete_space: function(space) {
smoke.confirm("Really delete "+space.name+"?", function(confirmed) { smoke.confirm(__("tool_delete_space", space.name), function(confirmed) {
if (!confirmed) return; if (!confirmed) return;
var idx = this.active_folder.children.indexOf(space); var idx = this.active_folder.children.indexOf(space);
@@ -502,7 +502,7 @@ var SpacedeckSpaces = {
this.active_folder.children.splice(idx,1); this.active_folder.children.splice(idx,1);
}.bind(this)); }.bind(this));
}.bind(this)); }.bind(this), {ok: __("ok"), cancel: __("cancel")});
}, },
duplicate_space: function(space) { duplicate_space: function(space) {
@@ -528,7 +528,7 @@ var SpacedeckSpaces = {
space.name = title; space.name = title;
save_space(space); save_space(space);
} }
}.bind(this), {value: space.name}); }.bind(this), {value: space.name, ok: __("ok"), cancel: __("cancel")});
}, },
rename_folder: function(folder) { rename_folder: function(folder) {
@@ -539,7 +539,7 @@ var SpacedeckSpaces = {
folder.name = title; folder.name = title;
save_space(folder); save_space(folder);
} }
}.bind(this), {value: folder.name}); }.bind(this), {value: folder.name, ok: __("ok"), cancel: __("cancel")});
}, },
edit_space_title: function() { edit_space_title: function() {

View File

@@ -130,27 +130,9 @@ SpacedeckUsers = {
$event.stopPropagation(); $event.stopPropagation();
} }
create_user(name, email, password, password_confirmation, invite_code, function(res) { create_user(name, email, password, password_confirmation, invite_code, function(session) {
this.creating_user = false; this.creating_user = false;
if (res.chargebee_checkout) {
var chargebeeInstance = Chargebee.init({
site: "spacedeck-test",
enableRedirectMode: true,
enableFriendbuyTracking: false
});
chargebeeInstance.openCheckout({
hostedPage: function() {
return new Promise(function(resolve, reject) {
resolve(res.chargebee_checkout);
})
}
});
} else {
// user created, login
this.login_submit(email, password, null, on_success); this.login_submit(email, password, null, on_success);
}
}.bind(this), function(req) { }.bind(this), function(req) {
this.creating_user = false; this.creating_user = false;
try { try {

View File

@@ -121,11 +121,17 @@ function boot_spacedeck() {
var lang = "en"; var lang = "en";
window.refreshLocale = function() { window.refreshLocale = function() {
if (spacedeck && spacedeck.user && spacedeck.user.preferences) { var old_lang = lang;
lang = spacedeck.user.preferences.language || "en"; if (spacedeck && spacedeck.user && spacedeck.user.prefs_language) {
lang = spacedeck.user.prefs_language || "en";
} else if (window.browser_lang) { } else if (window.browser_lang) {
lang = window.browser_lang; lang = window.browser_lang;
} }
if (lang != old_lang) {
i18n.init({ lng: lang, resStore: window.locales }, function(err, t) {
console.log("i18n initialized: "+lang);
});
}
} }
window.refreshLocale(); window.refreshLocale();

File diff suppressed because one or more lines are too long

View File

@@ -23,8 +23,6 @@ var express = require('express');
var router = express.Router(); var router = express.Router();
var glob = require('glob'); var glob = require('glob');
var chargebee = require('chargebee');
router.get('/current', function(req, res, next) { router.get('/current', function(req, res, next) {
if (req.user) { if (req.user) {
var u = _.clone(req.user.dataValues); var u = _.clone(req.user.dataValues);
@@ -41,32 +39,35 @@ router.get('/current', function(req, res, next) {
} }
}); });
function createChargebeeCheckout(req, res, plan_id, email, name, company) { // create user
var nameParts = name.split(" "); router.post('/', function(req, res) {
var firstName = nameParts.shift(); if (!req.body["email"] || !req.body["password"]) {
var lastName = nameParts.join(" "); res.status(400).json({"error":"email or password missing"});
return;
chargebee.hosted_page.checkout_new({
subscription: {
plan_id: plan_id
},
customer: {
first_name: firstName,
last_name: lastName,
email: email,
company: company,
} }
}).request(function(error,result) {
if (error) {
console.log(error);
res.status(400).json({"error":error+""});
} else {
res.status(200).json({"chargebee_checkout":result.hosted_page});
}
});
};
function createUser(req, res, email, nickname, password) { var email = req.body["email"].toLowerCase();
var nickname = req.body["nickname"];
var password = req.body["password"];
var password_confirmation = req.body["password_confirmation"];
var invite_code = req.body["invite_code"];
if (password_confirmation != password) {
res.status(400).json({"error":"password_confirmation"});
return;
}
if (config.invite_code && invite_code != config.invite_code) {
res.status(400).json({"error":"Invalid Invite Code."});
return;
}
if (!validator.isEmail(email)) {
res.status(400).json({"error":"email_invalid"});
return;
}
var createUser = function() {
bcrypt.genSalt(10, function(err, salt) { bcrypt.genSalt(10, function(err, salt) {
bcrypt.hash(password, salt, function(err, hash) { bcrypt.hash(password, salt, function(err, hash) {
crypto.randomBytes(16, function(ex, buf) { crypto.randomBytes(16, function(ex, buf) {
@@ -123,46 +124,10 @@ function createUser(req, res, email, nickname, password) {
}); });
}; };
// create user
router.post('/', function(req, res) {
if (!req.body["email"] || !req.body["password"]) {
res.status(400).json({"error":"email or password missing"});
return;
}
var email = req.body["email"].toLowerCase();
var nickname = req.body["nickname"];
var password = req.body["password"];
var password_confirmation = req.body["password_confirmation"];
var invite_code = req.body["invite_code"];
var company = req.body["company"] || "";
if (password_confirmation != password) {
res.status(400).json({"error":"password_confirmation"});
return;
}
if (config.invite_code && invite_code != config.invite_code) {
res.status(400).json({"error":"Invalid Invite Code."});
return;
}
if (!validator.isEmail(email)) {
res.status(400).json({"error":"email_invalid"});
return;
}
db.User.findAll({where: {email: email}}) db.User.findAll({where: {email: email}})
.then(users => { .then(users => {
if (users.length == 0) { if (users.length == 0) {
if (config.get('chargebee_integration')) { createUser();
// sign up via paid plan trial
createChargebeeCheckout(req, res, config.get('chargebee_default_plan_id'), email, nickname, company);
// TODO: createUser after chargebee checkout
}
else {
createUser(req, res, email, nickname, password);
}
} else { } else {
res.status(400).json({"error":"user_email_already_used"}); res.status(400).json({"error":"user_email_already_used"});
} }
@@ -324,7 +289,7 @@ router.post('/password_reset_requests/:confirm_token/confirm', function(req, res
bcrypt.genSalt(10, (err, salt) => { bcrypt.genSalt(10, (err, salt) => {
bcrypt.hash(password, salt, function(err, hash) { bcrypt.hash(password, salt, function(err, hash) {
user.password_hash = hash; user.password_hash = hash;
user.password_token = null; user.password_reset_token = null;
user.save().then(function(updatedUser) { user.save().then(function(updatedUser) {
res.sendStatus(201); res.sendStatus(201);
}); });

View File

@@ -23,8 +23,6 @@ const express = require('express');
const app = express(); const app = express();
const serveStatic = require('serve-static'); const serveStatic = require('serve-static');
const chargebee = require('chargebee');
const isProduction = app.get('env') === 'production'; const isProduction = app.get('env') === 'production';
// workaround for libssl_conf.so error triggered by phantomjs // workaround for libssl_conf.so error triggered by phantomjs
@@ -63,7 +61,7 @@ app.use(bodyParser.urlencoded({
})); }));
app.use(cookieParser()); app.use(cookieParser());
//app.use(helmet.frameguard()) //app.use(helmet.frameguard({ action: 'SAMEORIGIN' }));
//app.use(helmet.xssFilter()) //app.use(helmet.xssFilter())
/*app.use(helmet.hsts({ /*app.use(helmet.hsts({
maxAge: 7776000000, maxAge: 7776000000,
@@ -112,14 +110,6 @@ if (app.get('env') == 'development') {
module.exports = app; module.exports = app;
// ChargeBee Integration (Optional)
if (config.get('chargebee_integration')) {
chargebee.configure({
site: config.get('chargebee_site'),
api_key: config.get('chargebee_api_key')
});
}
// CONNECT TO DATABASE // CONNECT TO DATABASE
db.init(); db.init();

View File

@@ -3,6 +3,7 @@
.artifact { .artifact {
position: relative; position: relative;
line-height: normal;
//-webkit-transform: translate3d(0,0,0); // hw accel //-webkit-transform: translate3d(0,0,0); // hw accel
iframe { iframe {

View File

@@ -3,7 +3,7 @@
<a class="btn btn-dark btn-md btn-round btn-icon" href="/spaces"> <a class="btn btn-dark btn-md btn-round btn-icon" href="/spaces">
<span class="icon icon-svg icon-sd6"></span> <span class="icon icon-svg icon-sd6"></span>
</a> </a>
<h5>Edit Account</h5> <h5><%=__('edit_account')%></h5>
</div> </div>
<div class="header-right pull-right"> <div class="header-right pull-right">
@@ -86,7 +86,7 @@
</div> </div>
<div class="form-group"> <div class="form-group">
<button class="btn btn-md btn-dark" v-on:click="save_user()">Save</button> <button class="btn btn-md btn-dark" v-on:click="save_user()"><%=__('save')%></button>
</div> </div>
</div> </div>
</div> </div>
@@ -158,7 +158,7 @@
</div> </div>
<div class="collapse" v-bind:class="{in:account=='terminate'}"> <div class="collapse" v-bind:class="{in:account=='terminate'}">
<h4>Terminate Account</h4> <h4><%=__('terminate_caption')%></h4>
<div class="modal-section labels-inline"> <div class="modal-section labels-inline">
<div class="form-group"> <div class="form-group">
<label class="label"><%=__("current_password")%></label> <label class="label"><%=__("current_password")%></label>
@@ -177,7 +177,7 @@
</div> </div>
<div class="modal-footer"> <div class="modal-footer">
<button class="btn btn-stroke-darken btn-md" v-on:click="remove_account(account_remove_password, account_remove_feedback)">Terminate Account</button> <button class="btn btn-stroke-darken btn-md" v-on:click="remove_account(account_remove_password, account_remove_feedback)"><%=__('terminate_caption')%></button>
</div> </div>
</div> </div>
</div> </div>

View File

@@ -36,7 +36,7 @@
<div class="center alert alert-danger" v-if="login_error">{{login_error}}</div> <div class="center alert alert-danger" v-if="login_error">{{login_error}}</div>
<div style="margin-top:2em"> <div style="margin-top:2em">
<a href="/password-reset">Forgot Password</a> <a href="/password-reset"><%= __("forgot_password") %></a>
</div> </div>
</form> </form>
</div> </div>

View File

@@ -43,8 +43,8 @@
<div class="space-empty" v-cloak v-if="active_view == 'space' && !present_mode && active_space_artifacts.length == 0"> <div class="space-empty" v-cloak v-if="active_view == 'space' && !present_mode && active_space_artifacts.length == 0">
<div class="table-fake"> <div class="table-fake">
<div class="cell"> <div class="cell">
<p>Use the toolbar to add content.<br> <p><%= __('tool_space_help_part_one')%><br>
You can also drop images or sound and video files.</p> <%= __('tool_space_help_part_two')%></p>
</div> </div>
</div> </div>
</div> </div>

View File

@@ -41,6 +41,11 @@
<span class="icon-label"><%=__("tool_arrow")%></span> <span class="icon-label"><%=__("tool_arrow")%></span>
</button> </button>
<button class="btn btn-icon-labeled btn-transparent" v-on:click="start_drawing_line()" v-bind:class="{active:active_tool=='line'}" title="<%=__("tool_line")%>">
<span class="icon icon-tool-line"></span>
<span class="icon-label"><%=__("tool_line")%></span>
</button>
<div class="dropdown bottom light center"> <div class="dropdown bottom light center">
<div class="btn-collapse in"> <div class="btn-collapse in">
<input type="file" multiple v-on:change="handle_image_file_upload($event)" id="image_file_upload" class="btn btn-transparent btn-icon-labeled" style="position: absolute; z-index: 1; opacity: 0;"> <input type="file" multiple v-on:change="handle_image_file_upload($event)" id="image_file_upload" class="btn btn-transparent btn-icon-labeled" style="position: absolute; z-index: 1; opacity: 0;">

View File

@@ -57,9 +57,6 @@
<script src="/javascripts/spacedeck_directives.js"></script> <script src="/javascripts/spacedeck_directives.js"></script>
<script src="/javascripts/spacedeck_vue.js"></script> <script src="/javascripts/spacedeck_vue.js"></script>
<!-- TODO: only include based on config -->
<script src="https://js.chargebee.com/v2/chargebee.js"></script>
<script>if (window.module) module = window.module;</script> <script>if (window.module) module = window.module;</script>
</head> </head>