Merge branch 'release-v0.17.0'

This commit is contained in:
David Baker 2018-10-16 11:09:33 +01:00
commit 17e84bf815
18 changed files with 10537 additions and 3214 deletions

View file

@ -1,3 +1,49 @@
Changes in [0.17.0](https://github.com/vector-im/riot-web/releases/tag/v0.17.0) (2018-10-16)
============================================================================================
[Full Changelog](https://github.com/vector-im/riot-web/compare/v0.17.0-rc.1...v0.17.0)
* Phased rollout of lazyloading
[\#7503](https://github.com/vector-im/riot-web/pull/7503)
* Update to latest electron builder
[\#7501](https://github.com/vector-im/riot-web/pull/7501)
Changes in [0.17.0-rc.1](https://github.com/vector-im/riot-web/releases/tag/v0.17.0-rc.1) (2018-10-11)
======================================================================================================
[Full Changelog](https://github.com/vector-im/riot-web/compare/v0.16.5...v0.17.0-rc.1)
* Revert "also commit the lock file when bumping version as it is now
committed to the repo"
[\#7483](https://github.com/vector-im/riot-web/pull/7483)
* Update from Weblate.
[\#7478](https://github.com/vector-im/riot-web/pull/7478)
* Fix riot-web Promise.defer warnings (#7409)
[\#7444](https://github.com/vector-im/riot-web/pull/7444)
* Use HTTPS cloning for riot-web too
[\#7459](https://github.com/vector-im/riot-web/pull/7459)
* Disable webpack-dev-server auto reload
[\#7463](https://github.com/vector-im/riot-web/pull/7463)
* Silence bluebird warnings
[\#7462](https://github.com/vector-im/riot-web/pull/7462)
* Fix reskindex on matrix-react-side not being called if using build script
[\#7443](https://github.com/vector-im/riot-web/pull/7443)
* Fix double-closed tags
[\#7454](https://github.com/vector-im/riot-web/pull/7454)
* Document how to turn off Piwik and bug reports (#6738)
[\#7435](https://github.com/vector-im/riot-web/pull/7435)
* also commit the lock file when bumping version as it is now committed to the
repo
[\#7429](https://github.com/vector-im/riot-web/pull/7429)
* Update a bunch of deps
[\#7393](https://github.com/vector-im/riot-web/pull/7393)
* Don't show mobile guide if deep linking
[\#7415](https://github.com/vector-im/riot-web/pull/7415)
* Don't show custom server bit on matrix.org
[\#7408](https://github.com/vector-im/riot-web/pull/7408)
* Update Webpack to version 4
[\#6620](https://github.com/vector-im/riot-web/pull/6620)
* Webpack4
[\#7387](https://github.com/vector-im/riot-web/pull/7387)
Changes in [0.16.6](https://github.com/vector-im/riot-web/releases/tag/v0.16.6) (2018-10-08) Changes in [0.16.6](https://github.com/vector-im/riot-web/releases/tag/v0.16.6) (2018-10-08)
============================================================================================ ============================================================================================
[Full Changelog](https://github.com/vector-im/riot-web/compare/v0.16.5...v0.16.6) [Full Changelog](https://github.com/vector-im/riot-web/compare/v0.16.5...v0.16.6)

View file

@ -134,7 +134,9 @@ For a good example, see https://riot.im/develop/config.json
1. `integrations_rest_url`: URL to the REST interface for the integrations server. 1. `integrations_rest_url`: URL to the REST interface for the integrations server.
1. `integrations_widgets_urls`: list of URLs to the REST interface for the widget integrations server. 1. `integrations_widgets_urls`: list of URLs to the REST interface for the widget integrations server.
1. `bug_report_endpoint_url`: endpoint to send bug reports to (must be running a 1. `bug_report_endpoint_url`: endpoint to send bug reports to (must be running a
https://github.com/matrix-org/rageshake server) https://github.com/matrix-org/rageshake server). Bug reports are sent when a user clicks
"Send Logs" within the application. Bug reports can be disabled by leaving the
`bug_report_endpoint_url` out of your config file.
1. `roomDirectory`: config for the public room directory. This section is optional. 1. `roomDirectory`: config for the public room directory. This section is optional.
1. `roomDirectory.servers`: List of other homeservers' directories to include in the drop 1. `roomDirectory.servers`: List of other homeservers' directories to include in the drop
down list. Optional. down list. Optional.
@ -147,11 +149,13 @@ For a good example, see https://riot.im/develop/config.json
anything else since it is used to isolate the privileges of file attachments to this anything else since it is used to isolate the privileges of file attachments to this
domain. Default: `https://usercontent.riot.im/v1.html`. This needs to contain v1.html from domain. Default: `https://usercontent.riot.im/v1.html`. This needs to contain v1.html from
https://github.com/matrix-org/usercontent/blob/master/v1.html https://github.com/matrix-org/usercontent/blob/master/v1.html
1. `piwik`: an object containing the following properties: 1. `piwik`: Analytics can be disabled by setting `piwik: false` or by leaving the piwik config
1. `url`: The URL of the Piwik instance to use for collecting Analytics option out of your config file. If you want to enable analytics, set `piwik` to be an object
1. `whitelistedHSUrls`: a list of HS URLs to not redact from the Analytics containing the following properties:
1. `whitelistedISUrls`: a list of IS URLs to not redact from the Analytics 1. `url`: The URL of the Piwik instance to use for collecting analytics
1. `siteId`: The Piwik Site ID to use when sending Analytics to the Piwik server configured above 1. `whitelistedHSUrls`: a list of HS URLs to not redact from the analytics
1. `whitelistedISUrls`: a list of IS URLs to not redact from the analytics
1. `siteId`: The Piwik Site ID to use when sending analytics to the Piwik server configured above
1. `teamServerConfig`, `teamTokenMap`, `referralBaseUrl`: an obsolete precursor to communities 1. `teamServerConfig`, `teamTokenMap`, `referralBaseUrl`: an obsolete precursor to communities
with referral tracking; please ignore it. with referral tracking; please ignore it.
1. `welcomeUserId`: the user ID of a bot to invite whenever users register that can give them a tour 1. `welcomeUserId`: the user ID of a bot to invite whenever users register that can give them a tour
@ -230,6 +234,10 @@ Before attempting to develop on Riot you **must** read the developer guide
for `matrix-react-sdk` at https://github.com/matrix-org/matrix-react-sdk, which for `matrix-react-sdk` at https://github.com/matrix-org/matrix-react-sdk, which
also defines the design, architecture and style for Riot too. also defines the design, architecture and style for Riot too.
You should also familiarise yourself with the "Here be Dragons" guide to the
tame & not-so-tame dragons (gotchas) which exist in the codebase:
https://docs.google.com/document/d/12jYzvkidrp1h7liEuLIe6BMdU0NUjndUYI971O06ooM
The idea of Riot is to be a relatively lightweight "skin" of customisations on The idea of Riot is to be a relatively lightweight "skin" of customisations on
top of the underlying `matrix-react-sdk`. `matrix-react-sdk` provides both the top of the underlying `matrix-react-sdk`. `matrix-react-sdk` provides both the
higher and lower level React components useful for building Matrix communication higher and lower level React components useful for building Matrix communication
@ -270,7 +278,7 @@ Then similarly with `matrix-react-sdk`:
Finally, build and start Riot itself: Finally, build and start Riot itself:
1. `git clone git@github.com:vector-im/riot-web.git` 1. `git clone https://github.com/vector-im/riot-web.git`
1. `cd riot-web` 1. `cd riot-web`
1. `git checkout develop` 1. `git checkout develop`
1. `npm install` 1. `npm install`

View file

@ -2,7 +2,7 @@
"name": "riot-web", "name": "riot-web",
"productName": "Riot", "productName": "Riot",
"main": "src/electron-main.js", "main": "src/electron-main.js",
"version": "0.16.6", "version": "0.17.0",
"description": "A feature-rich client for Matrix.org", "description": "A feature-rich client for Matrix.org",
"author": "Vector Creations Ltd.", "author": "Vector Creations Ltd.",
"dependencies": { "dependencies": {

View file

@ -21,6 +21,15 @@
"siteId": 1, "siteId": 1,
"policyUrl": "https://matrix.org/docs/guides/riot_im_cookie_policy" "policyUrl": "https://matrix.org/docs/guides/riot_im_cookie_policy"
}, },
"phasedRollOut": {
"feature_lazyloading": {
"offset": 1539684000000,
"period": 604800000
}
},
"features": {
"feature_lazyloading": "enable"
},
"enable_presence_by_hs_url": { "enable_presence_by_hs_url": {
"https://matrix.org": false "https://matrix.org": false
} }

View file

@ -32,9 +32,12 @@ const olm_entry = webpack_config.entry['olm'];
// 'preprocessors' config below) // 'preprocessors' config below)
delete webpack_config['entry']; delete webpack_config['entry'];
// make sure we're flagged as development to avoid wasting time optimising
webpack_config.mode = 'development';
// add ./test as a search path for js // add ./test as a search path for js
webpack_config.module.loaders.unshift({ webpack_config.module.rules.unshift({
test: /\.js$/, loader: "babel", test: /\.js$/, use: "babel-loader",
include: [path.resolve('./src'), path.resolve('./test')], include: [path.resolve('./src'), path.resolve('./test')],
}); });
@ -46,8 +49,9 @@ webpack_config.module.noParse.push(/sinon\/pkg\/sinon\.js$/);
// ? // ?
webpack_config.resolve.alias['sinon'] = 'sinon/pkg/sinon.js'; webpack_config.resolve.alias['sinon'] = 'sinon/pkg/sinon.js';
webpack_config.resolve.root = [ webpack_config.resolve.modules = [
path.resolve('./test'), path.resolve('./test'),
"node_modules"
]; ];
webpack_config.devtool = 'inline-source-map'; webpack_config.devtool = 'inline-source-map';

13195
package-lock.json generated

File diff suppressed because it is too large Load diff

View file

@ -2,7 +2,7 @@
"name": "riot-web", "name": "riot-web",
"productName": "Riot", "productName": "Riot",
"main": "electron_app/src/electron-main.js", "main": "electron_app/src/electron-main.js",
"version": "0.16.6", "version": "0.17.0",
"description": "A feature-rich client for Matrix.org", "description": "A feature-rich client for Matrix.org",
"author": "New Vector Ltd.", "author": "New Vector Ltd.",
"repository": { "repository": {
@ -33,10 +33,10 @@
"build:res": "node scripts/copy-res.js", "build:res": "node scripts/copy-res.js",
"build:modernizr": "modernizr -c .modernizr.json -d src/vector/modernizr.js", "build:modernizr": "modernizr -c .modernizr.json -d src/vector/modernizr.js",
"build:compile": "npm run reskindex && babel --source-maps -d lib src", "build:compile": "npm run reskindex && babel --source-maps -d lib src",
"build:bundle": "cross-env NODE_ENV=production webpack -p --progress --bail", "build:bundle": "cross-env NODE_ENV=production webpack-cli -p --progress --bail --mode production",
"build:bundle:dev": "webpack --optimize-occurence-order --progress --bail", "build:bundle:dev": "webpack-cli --progress --bail --mode development",
"build:electron": "npm run clean && npm run build && npm run install:electron && build -wml --ia32 --x64", "build:electron": "npm run clean && npm run build && npm run install:electron && build -wml --ia32 --x64",
"build:react-sdk": "node scripts/npm-sub.js matrix-react-sdk run start:init", "build:react-sdk": "node scripts/npm-sub.js matrix-react-sdk run build",
"build:js-sdk": "node scripts/npm-sub.js matrix-js-sdk run start:init", "build:js-sdk": "node scripts/npm-sub.js matrix-js-sdk run start:init",
"build": "npm run build:js-sdk && npm run build:react-sdk && npm run reskindex && npm run build:res && npm run build:bundle", "build": "npm run build:js-sdk && npm run build:react-sdk && npm run reskindex && npm run build:res && npm run build:bundle",
"build:dev": "npm run build:js-sdk && npm run build:react-sdk && npm run reskindex && npm run build:res && npm run build:bundle:dev", "build:dev": "npm run build:js-sdk && npm run build:react-sdk && npm run reskindex && npm run build:res && npm run build:bundle:dev",
@ -44,7 +44,7 @@
"install:electron": "install-app-deps", "install:electron": "install-app-deps",
"electron": "npm run install:electron && electron .", "electron": "npm run install:electron && electron .",
"start:res": "node scripts/copy-res.js -w", "start:res": "node scripts/copy-res.js -w",
"start:js": "webpack-dev-server --output-filename=bundles/_dev_/[name].js --output-chunk-file=bundles/_dev_/[name].js -w --progress", "start:js": "webpack-dev-server --output-filename=bundles/_dev_/[name].js --output-chunk-filename=bundles/_dev_/[name].js -w --progress --mode development",
"start:js:prod": "cross-env NODE_ENV=production webpack-dev-server -w --progress", "start:js:prod": "cross-env NODE_ENV=production webpack-dev-server -w --progress",
"start:js-sdk": "node scripts/npm-sub.js matrix-js-sdk run start:watch", "start:js-sdk": "node scripts/npm-sub.js matrix-js-sdk run start:watch",
"start:js-sdk:prod": "cross-env NODE_ENV=production node scripts/npm-sub.js matrix-js-sdk run start:watch", "start:js-sdk:prod": "cross-env NODE_ENV=production node scripts/npm-sub.js matrix-js-sdk run start:watch",
@ -60,101 +60,97 @@
"test-multi": "karma start" "test-multi": "karma start"
}, },
"dependencies": { "dependencies": {
"babel-polyfill": "^6.5.0", "babel-polyfill": "^6.26.0",
"babel-runtime": "^6.11.6", "babel-runtime": "^6.26.0",
"bluebird": "^3.5.0", "bluebird": "^3.5.2",
"browser-request": "^0.3.3", "browser-request": "^0.3.3",
"draft-js": "^0.11.0-alpha", "draft-js": "^0.11.0-alpha",
"extract-text-webpack-plugin": "^0.9.1", "extract-text-webpack-plugin": "^4.0.0-beta.0",
"favico.js": "^0.3.10", "favico.js": "^0.3.10",
"gemini-scrollbar": "matrix-org/gemini-scrollbar#b302279", "gemini-scrollbar": "github:matrix-org/gemini-scrollbar#b302279",
"gfm.css": "^1.1.1", "gfm.css": "^1.1.2",
"highlight.js": "^9.0.0", "highlight.js": "^9.0.0",
"matrix-js-sdk": "0.11.1", "matrix-js-sdk": "0.12.0",
"matrix-react-sdk": "0.13.6", "matrix-react-sdk": "0.14.0",
"modernizr": "^3.1.0", "modernizr": "^3.6.0",
"prop-types": "^15.5.10", "prop-types": "^15.6.2",
"react": "^15.6.0", "react": "^15.6.0",
"react-dom": "^15.6.0", "react-dom": "^15.6.0",
"sanitize-html": "^1.18.4", "sanitize-html": "^1.18.4",
"ua-parser-js": "^0.7.10", "ua-parser-js": "^0.7.18",
"url": "^0.11.0" "url": "^0.11.0"
}, },
"devDependencies": { "devDependencies": {
"autoprefixer": "^6.6.0", "autoprefixer": "^6.6.0",
"babel-cli": "^6.5.2", "babel-cli": "^6.26.0",
"babel-core": "^6.14.0", "babel-core": "^6.26.3",
"babel-eslint": "^6.1.0", "babel-eslint": "^6.1.2",
"babel-loader": "^6.2.5", "babel-loader": "^7.1.5",
"babel-plugin-add-module-exports": "^0.2.1", "babel-plugin-add-module-exports": "^0.2.1",
"babel-plugin-transform-async-to-bluebird": "^1.1.1", "babel-plugin-transform-async-to-bluebird": "^1.1.1",
"babel-plugin-transform-class-properties": "^6.16.0", "babel-plugin-transform-class-properties": "^6.24.1",
"babel-plugin-transform-object-rest-spread": "^6.16.0", "babel-plugin-transform-object-rest-spread": "^6.26.0",
"babel-plugin-transform-runtime": "^6.15.0", "babel-plugin-transform-runtime": "^6.23.0",
"babel-preset-es2015": "^6.16.0", "babel-preset-es2015": "^6.24.1",
"babel-preset-es2016": "^6.16.0", "babel-preset-es2016": "^6.24.1",
"babel-preset-es2017": "^6.16.0", "babel-preset-es2017": "^6.24.1",
"babel-preset-react": "^6.16.0", "babel-preset-react": "^6.24.1",
"babel-preset-stage-2": "^6.17.0", "babel-preset-stage-2": "^6.24.1",
"chokidar": "^1.6.1", "chokidar": "^1.6.1",
"concurrently": "^4.0.1", "concurrently": "^4.0.1",
"cpx": "^1.3.2", "cpx": "^1.3.2",
"cross-env": "^4.0.0", "cross-env": "^4.0.0",
"css-raw-loader": "^0.1.1", "electron-builder": "^20.28.4",
"electron-builder": "^11.2.4", "electron-builder-squirrel-windows": "^11.6.1",
"electron-builder-squirrel-windows": "^11.2.1", "electron-devtools-installer": "^2.2.4",
"electron-devtools-installer": "^2.2.0",
"emojione": "^2.2.7", "emojione": "^2.2.7",
"eslint": "^3.14.0", "eslint": "^5.6.0",
"eslint-config-google": "^0.7.1", "eslint-config-google": "^0.7.1",
"eslint-plugin-babel": "^4.1.1", "eslint-plugin-babel": "^4.1.2",
"eslint-plugin-flowtype": "^2.30.0", "eslint-plugin-flowtype": "^2.50.3",
"eslint-plugin-react": "^7.4.0", "eslint-plugin-react": "^7.11.1",
"expect": "^1.16.0", "expect": "^1.16.0",
"fs-extra": "^0.30.0", "fs-extra": "^0.30.0",
"html-webpack-plugin": "^2.24.0", "html-webpack-plugin": "^3.2.0",
"json-loader": "^0.5.3", "json-loader": "^0.5.3",
"karma": "^1.7.0", "karma": "^3.0.0",
"karma-chrome-launcher": "^0.2.3", "karma-chrome-launcher": "^0.2.3",
"karma-cli": "^0.1.2", "karma-cli": "^1.0.1",
"karma-junit-reporter": "^0.4.1", "karma-junit-reporter": "^2.0.0",
"karma-logcapture-reporter": "0.0.1", "karma-logcapture-reporter": "0.0.1",
"karma-mocha": "^0.2.2", "karma-mocha": "^1.3.0",
"karma-sourcemap-loader": "^0.3.7", "karma-sourcemap-loader": "^0.3.7",
"karma-spec-reporter": "0.0.31", "karma-spec-reporter": "0.0.31",
"karma-summary-reporter": "^1.3.3", "karma-summary-reporter": "^1.5.1",
"karma-webpack": "^1.7.0", "karma-webpack": "4.0.0-beta.0",
"matrix-mock-request": "^1.2.0", "matrix-mock-request": "^1.2.0",
"matrix-react-test-utils": "^0.2.0", "matrix-react-test-utils": "^0.2.0",
"minimist": "^1.2.0", "minimist": "^1.2.0",
"mkdirp": "^0.5.1", "mkdirp": "^0.5.1",
"mocha": "^2.4.5", "mocha": "^5.2.0",
"postcss-extend": "^1.0.5", "postcss-extend": "^1.0.5",
"postcss-import": "^9.0.0", "postcss-import": "^11.1.0",
"postcss-loader": "^1.2.2", "postcss-loader": "^2.1.6",
"postcss-mixins": "^5.4.1", "postcss-mixins": "^6.2.0",
"postcss-nested": "^1.0.0", "postcss-nested": "^3.0.0",
"postcss-scss": "^0.4.0", "postcss-scss": "^1.0.6",
"postcss-simple-vars": "^3.0.0", "postcss-simple-vars": "^4.1.0",
"postcss-strip-inline-comments": "^0.1.5", "postcss-strip-inline-comments": "^0.1.5",
"raw-loader": "^0.5.1",
"react-addons-perf": "^15.4.0", "react-addons-perf": "^15.4.0",
"react-addons-test-utils": "^15.6.0", "react-addons-test-utils": "^15.6.0",
"rimraf": "^2.4.3", "rimraf": "^2.4.3",
"source-map-loader": "^0.2.3", "source-map-loader": "^0.2.4",
"webpack": "^1.12.14", "webpack": "^4.20.2",
"webpack-dev-server": "^1.16.2" "webpack-cli": "^3.1.1",
"webpack-dev-server": "^3.1.9"
}, },
"optionalDependencies": { "optionalDependencies": {
"olm": "https://matrix.org/packages/npm/olm/olm-2.2.1.tgz" "olm": "https://matrix.org/packages/npm/olm/olm-2.2.1.tgz"
}, },
"build": { "build": {
"appId": "im.riot.app", "appId": "im.riot.app",
"category": "Network", "electronVersion": "3.0.3",
"electronVersion": "2.0.8",
"//asar=false": "https://github.com/electron-userland/electron-builder/issues/675",
"asar": false,
"dereference": true,
"//files": "We bundle everything, so we only need to include webapp/",
"files": [ "files": [
"node_modules/**", "node_modules/**",
"src/**", "src/**",
@ -171,8 +167,13 @@
"StartupWMClass": "riot" "StartupWMClass": "riot"
} }
}, },
"mac": {
"category": "public.app-category.social-networking"
},
"win": { "win": {
"target": {
"target": "squirrel" "target": "squirrel"
}
}, },
"directories": { "directories": {
"buildResources": "electron_app/build", "buildResources": "electron_app/build",

View file

@ -100,7 +100,7 @@ mkdir -p "$projdir/electron_app/dist/unsigned/"
# Install packages: what the user downloads the first time, # Install packages: what the user downloads the first time,
# (DMGs for mac, exe installer for windows) # (DMGs for mac, exe installer for windows)
mkdir -p "$pubdir/install/macos" mkdir -p "$pubdir/install/macos"
cp $distdir/mac/*.dmg "$pubdir/install/macos/" cp $distdir/*.dmg "$pubdir/install/macos/"
# Windows installers go to the dist dir because they need signing # Windows installers go to the dist dir because they need signing
mkdir -p "$pubdir/install/win32/ia32/" mkdir -p "$pubdir/install/win32/ia32/"
@ -111,7 +111,7 @@ cp $distdir/win/*.exe "$projdir/electron_app/dist/unsigned/"
# Packages for auto-update # Packages for auto-update
mkdir -p "$pubdir/update/macos" mkdir -p "$pubdir/update/macos"
cp $distdir/mac/*.zip "$pubdir/update/macos/" cp $distdir/*-mac.zip "$pubdir/update/macos/"
echo "$vername" > "$pubdir/update/macos/latest" echo "$vername" > "$pubdir/update/macos/latest"
mkdir -p "$pubdir/update/win32/ia32/" mkdir -p "$pubdir/update/win32/ia32/"

View file

@ -22,18 +22,18 @@
"Support for those using and running matrix-appservice-irc": "Supporto per chi usa e amministra matrix-appservice-irc", "Support for those using and running matrix-appservice-irc": "Supporto per chi usa e amministra matrix-appservice-irc",
"Building services on Matrix": "Costruzione servizi su Matrix", "Building services on Matrix": "Costruzione servizi su Matrix",
"Support for those using the Matrix spec": "Supporto per chi utilizza le specifiche Matrix", "Support for those using the Matrix spec": "Supporto per chi utilizza le specifiche Matrix",
"Design and implementation of E2E in Matrix": "Design e implementazione di E2E in Matrix", "Design and implementation of E2E in Matrix": "Progetto e implementazione di E2E in Matrix",
"Implementing VR services with Matrix": "Implementazione servizi VR con Matrix", "Implementing VR services with Matrix": "Implementazione servizi VR con Matrix",
"Implementing VoIP services with Matrix": "Implementazione servizi VoIP con Matrix", "Implementing VoIP services with Matrix": "Implementazione servizi VoIP con Matrix",
"Discussion of the Identity Service API": "Discussione sull'Identity Service API", "Discussion of the Identity Service API": "Discussione API del servizio identità",
"Support for those using, running and writing other bridges": "Supporto per chi usa, amministra e scrive altri bridge", "Support for those using, running and writing other bridges": "Supporto per chi usa, amministra e scrive altri ponti (bridge)",
"Contributing code to Matrix and Riot": "Contributi di codice per Matrix e Riot", "Contributing code to Matrix and Riot": "Contributi di codice per Matrix e Riot",
"%(appName)s via %(browserName)s on %(osName)s": "%(appName)s tramite %(browserName)s su %(osName)s", "%(appName)s via %(browserName)s on %(osName)s": "%(appName)s tramite %(browserName)s su %(osName)s",
"Decentralised, encrypted chat & collaboration powered by [matrix]": "Chat criptate e collaborazioni decentralizzate offerte da [matrix]", "Decentralised, encrypted chat & collaboration powered by [matrix]": "Chat criptate e decentralizzate & collaborazione offerta da [matrix]",
"Discussion of all things Matrix!": "Discussione su tutto quanto riguardi Matrix!", "Discussion of all things Matrix!": "Discussione su tutto riguardo Matrix!",
"Dev chat for the Riot/Web dev team": "Chat per gli sviluppatori di Riot/Web", "Dev chat for the Riot/Web dev team": "Chat per gli sviluppatori di Riot/Web",
"Dev chat for the Dendrite dev team": "Chat per gli sviluppatori di Dendrite", "Dev chat for the Dendrite dev team": "Chat per gli sviluppatori di Dendrite",
"Lots of rooms already exist in Matrix, linked to existing networks (Slack, IRC, Gitter etc) or independent. Check out the directory!": "Esistono già molte stanze in Matrix, collegate a reti già esistenti (Slack, IRC, Gitter ecc) o indipendenti. Dai un'occhiata all'elenco!", "Lots of rooms already exist in Matrix, linked to existing networks (Slack, IRC, Gitter etc) or independent. Check out the directory!": "Esistono già molte stanze in Matrix, collegate a reti esistenti (Slack, IRC, Gitter, ecc.) o indipendenti. Controlla l'elenco!",
"You can use the custom server options to sign into other Matrix servers by specifying a different Home server URL.<br/>This allows you to use Riot with an existing Matrix account on a different home server.<br/><br/>You can also set a custom identity server but you won't be able to invite users by email address, or be invited by email address yourself.": "Puoi usare le opzioni server personalizzate per accedere ad altri server Matrix specificando l'indirizzo dell'home server.<br/> Questo permette di usare Matrix con un account esistente su un home server diverso.<br/><br/>È anche possibile impostare un diverso identity server, ma in quel caso non sarà possibile invitare utenti attraverso l'indirizzo e-mail o essere invitati attraverso l'indirizzo e-mail.", "You can use the custom server options to sign into other Matrix servers by specifying a different Home server URL.<br/>This allows you to use Riot with an existing Matrix account on a different home server.<br/><br/>You can also set a custom identity server but you won't be able to invite users by email address, or be invited by email address yourself.": "Puoi usare le opzioni server personalizzate per accedere ad altri server Matrix specificando l'indirizzo del server home.<br/> Questo permette di usare Riot con un account Matrix esistente su un server home diverso.<br/><br/>È anche possibile impostare un diverso server identità, ma in tal caso non sarà possibile invitare utenti attraverso l'indirizzo e-mail o essere invitati attraverso l'indirizzo e-mail.",
"Co-ordination for Riot translators": "Coordinazione per i traduttori di Riot" "Co-ordination for Riot translators": "Coordinazione per i traduttori di Riot"
} }

View file

@ -15,7 +15,7 @@
"Chat with Riot Bot": "Riot Botと会話", "Chat with Riot Bot": "Riot Botと会話",
"Get started with some tips from Riot Bot!": "Riot Botにヒントをもらって始めましょう", "Get started with some tips from Riot Bot!": "Riot Botにヒントをもらって始めましょう",
"General discussion about Matrix and Riot": "MatrixとRiotの概略", "General discussion about Matrix and Riot": "MatrixとRiotの概略",
"Discussion of all things Matrix!": "Matrixなんでも討論", "Discussion of all things Matrix!": "Matrixなんでも議論!",
"Riot/Web &amp; Desktop chat": "Riot/Web &amp; デスクトップ版チャット", "Riot/Web &amp; Desktop chat": "Riot/Web &amp; デスクトップ版チャット",
"Riot/iOS &amp; matrix-ios-sdk chat": "Riot/iOS &amp; matrix-ios-sdk チャット", "Riot/iOS &amp; matrix-ios-sdk chat": "Riot/iOS &amp; matrix-ios-sdk チャット",
"Riot/Android &amp; matrix-android-sdk chat": "Riot/Android &amp; matrix-android-sdk チャット", "Riot/Android &amp; matrix-android-sdk chat": "Riot/Android &amp; matrix-android-sdk チャット",
@ -27,12 +27,13 @@
"Support for those using and running matrix-appservice-irc": "matrix-appservice-ircを利用並びに運営している方へのサポート", "Support for those using and running matrix-appservice-irc": "matrix-appservice-ircを利用並びに運営している方へのサポート",
"Building services on Matrix": "Matrixでのサービスの開発", "Building services on Matrix": "Matrixでのサービスの開発",
"Support for those using the Matrix spec": "Matrixスペックを利用する方へのサポート", "Support for those using the Matrix spec": "Matrixスペックを利用する方へのサポート",
"Design and implementation of E2E in Matrix": "Matrixのデザインとエンドツーエンドの実装", "Design and implementation of E2E in Matrix": "Matrixのデザインとエンドツーエンドの実装",
"Implementing VR services with Matrix": "MatrixでのVRサービスの実装", "Implementing VR services with Matrix": "MatrixでのVRサービスの実装",
"Implementing VoIP services with Matrix": "MatrixでのIP電話サービスの実装", "Implementing VoIP services with Matrix": "MatrixでのIP電話サービスの実装",
"Discussion of the Identity Service API": "Identity Service APIの議論", "Discussion of the Identity Service API": "Identity Service APIの議論",
"Support for those using, running and writing other bridges": "他のブリッジを利用、運営、作成している方へのサポート", "Support for those using, running and writing other bridges": "他のブリッジを利用、運営、作成している方へのサポート",
"Contributing code to Matrix and Riot": "MatrixとRiotにコードを提供する", "Contributing code to Matrix and Riot": "MatrixとRiotにコードを提供する",
"Dev chat for the Riot/Web dev team": "Riot/Web開発者チームのための開発者チャット", "Dev chat for the Riot/Web dev team": "Riot/Web開発者チームのための開発者チャット",
"Dev chat for the Dendrite dev team": "Dendrite開発者チームのための開発者チャット" "Dev chat for the Dendrite dev team": "Dendrite開発者チームのための開発者チャット",
"Co-ordination for Riot translators": "Riot 翻訳者による共同作業"
} }

39
src/i18n/strings/jbo.json Normal file
View file

@ -0,0 +1,39 @@
{
"Riot is not supported on mobile web. Install the app?": ".i lo samfonxa na kakne lo nu pilno la kibro nu zunti .i .au pei kibycpa le samtci",
"Riot Desktop on %(platformName)s": "la skami nu zunti ci'e la'o gy. %(platformName)s .gy.",
"Unknown device": "lo na'e te djuno se pilno",
"%(appName)s via %(browserName)s on %(osName)s": "la'o gy. %(appName)s .gy. xe be'i la'o gy. %(browserName)s .gy. ci'e la'o gy. %(osName)s .gy.",
"You need to be using HTTPS to place a screen-sharing call.": ".i la .hytytypysys. sarcu lo nu co'a vidni jorne",
"Custom Server Options": "lo macnu se cuxna be fi lo'i samse'u",
"You can use the custom server options to sign into other Matrix servers by specifying a different Home server URL.<br/>This allows you to use Riot with an existing Matrix account on a different home server.<br/><br/>You can also set a custom identity server but you won't be able to invite users by email address, or be invited by email address yourself.": ".i zukte lo nu macnu cuxna lo samse'u kei goi ko'a lo nu pilno lo drata samse'u pe la nacmeimei<br/>.i ko'a se cumki lo nu do pilno lo pilno poi zvati lo drata samse'u pe la nacmeimei<br/><br/>.i ji'a cumki fa lo nu do pilno lo drata ke prenu datni samse'u kei goi ko'a .i ku'i ko'a to'e rinka la'a lo nu do zvacpe ja se zvacpe",
"Dismiss": "mipri",
"powered by Matrix": ".i la nacmeimei cu cumgau",
"Welcome to Riot.im": ".i fi'i lo pilno be la nu zunti",
"Decentralised, encrypted chat &amp; collaboration powered by [matrix]": ".i la nacmeimei cu cumgau lo mifra je na'e se midju nu tavla je ke kansa gunka",
"Search the room directory": "sisku fi lo'i kumfa pe'a",
"Lots of rooms already exist in Matrix, linked to existing networks (Slack, IRC, Gitter etc) or independent. Check out the directory!": ".i ci'e la nacmeimei cu kumfa pe'a fa so'i da noi jorne jo nai no'e jorne lo drata ciste no'u mu'a la .slak. jo'u lo te irci jo'u la .gityr. .i",
"Chat with Riot Bot": "tavla la nu zunti kei sampre",
"Get started with some tips from Riot Bot!": ".i .e'u la nu zunti kei sampre cu sidju ko",
"General discussion about Matrix and Riot": "lo nu casnu be la nacmeimei .e la nu zunti",
"Discussion of all things Matrix!": "lo nu casnu be ro me la nacmeimei",
"Riot/Web &amp; Desktop chat": "lo nu casnu be la kibro nu zunti .e la skami nu zunti",
"Running Matrix services": "lo nu ralte lo samtcise'u pe la nacmeimei",
"Community-run support for Synapse": "lo nu lo cecmu cu sidju fi tu'a la .sinaps.",
"Discussion of the Identity Service API": "lo nu casnu lo prenu datni favgau cimde",
"Contributing code to Matrix and Riot": "lo nu dunda lo samselpla la nacmeimei .a la nu zunti",
"Co-ordination for Riot translators": "lo nu lo fanva pe la nu zunti cu kansa gunka",
"Riot/iOS &amp; matrix-ios-sdk chat": "lo nu casnu la plisyfonkemsamcmu nu zunti .e la'o gy. matrix-ios-sdk .gy.",
"Riot/Android &amp; matrix-android-sdk chat": "lo nu casnu la guglyfonkemsamcmu nu zunti .e la'o gy. matrix-android-sdk .gy.",
"Matrix technical discussions": "lo nu casnu lo zbaske be la nacmeimei",
"Announcements about Synapse releases": "lo notci be lo farvi tcini pe la nirna",
"Support for those using and running matrix-appservice-irc": "lo nu sidju lo pilno ja admine be la'o gy. matrix-appservice-irc .gy.",
"Building services on Matrix": "lo nu finti lo te selfu ji'u la nacmeimei",
"Support for those using the Matrix spec": "lo nu sidju lo pilno be lo sarcu pe la nacmeimei",
"Design and implementation of E2E in Matrix": "lo nu finti lo mulno mifra te platu .a lo samtcise'u be my. ji'u la nacmeimei",
"Support for those using, running and writing other bridges": "lo nu sidju lo pilno ja admine ja finti be lo drata te jorne",
"Dev chat for the Riot/Web dev team": "lo nu lo favgau be la kibro nu zunti cu casnu",
"Dev chat for the Dendrite dev team": "lo nu lo favgau be la nirndendriti cu casnu",
"Implementing VoIP services with Matrix": "lo nu finti lo samtcise'u be fi la .voip. ji'u la nacmeimei",
"Implementing VR services with Matrix": "lo nu finti lo samtcise'u be fi lo na'e fatci munje ji'u la nacmeimei",
"Admin support for Dendrite": "lo nu sidju lo admine be la nirndendriti"
}

View file

@ -33,5 +33,7 @@
"Contributing code to Matrix and Riot": "Matrix와 Riot에 코드 기여하기", "Contributing code to Matrix and Riot": "Matrix와 Riot에 코드 기여하기",
"Dev chat for the Riot/Web dev team": "Riot/웹 개발 팀을 위한 개발자 대화", "Dev chat for the Riot/Web dev team": "Riot/웹 개발 팀을 위한 개발자 대화",
"Dev chat for the Dendrite dev team": "덴드라이트 개발 팀을 위한 개발자 대화", "Dev chat for the Dendrite dev team": "덴드라이트 개발 팀을 위한 개발자 대화",
"Lots of rooms already exist in Matrix, linked to existing networks (Slack, IRC, Gitter etc) or independent. Check out the directory!": "기존 네트워크(Slack, IRC, Gitter 등)에 연결되있거나 독립된 많은 방이 이미 Matrix에 있습니다. 목록을 확인해보세요!" "Lots of rooms already exist in Matrix, linked to existing networks (Slack, IRC, Gitter etc) or independent. Check out the directory!": "기존 네트워크(Slack, IRC, Gitter 등)에 연결되있거나 독립된 많은 방이 이미 Matrix에 있습니다. 목록을 확인해보세요!",
"Co-ordination for Riot translators": "Riot 번역자 조합",
"You can use the custom server options to sign into other Matrix servers by specifying a different Home server URL.<br/>This allows you to use Riot with an existing Matrix account on a different home server.<br/><br/>You can also set a custom identity server but you won't be able to invite users by email address, or be invited by email address yourself.": "사용자정의 서버 설정에서 다른 홈서버 URL를 지정해 다른 Matrix 서버에 접속할 수 있습니다. <br/>이렇게하면 다른 홈서버에서 기존의 Matrix 계정으로 Riot을 이용할 수 있습니다.<br/><br/>사용자정의 아이덴티티 서버도 설정할 수 있지만 이메일 주소로 이용자를 초대하거나 자신이 이메일 주소로 초대받을 수 없습니다."
} }

View file

@ -1,5 +1,5 @@
{ {
"Riot is not supported on mobile web. Install the app?": "Riot-i nuk mbulohet nën web për celularët. Të instalohet aplikacioni?", "Riot is not supported on mobile web. Install the app?": "Riot-i nuk mbulohet në web për celularë. Të instalohet aplikacioni?",
"Riot Desktop on %(platformName)s": "Riot Desktop në %(platformName)s", "Riot Desktop on %(platformName)s": "Riot Desktop në %(platformName)s",
"Unknown device": "Pajisje e panjohur", "Unknown device": "Pajisje e panjohur",
"%(appName)s via %(browserName)s on %(osName)s": "%(appName)s përmes %(browserName)s nën %(osName)s", "%(appName)s via %(browserName)s on %(osName)s": "%(appName)s përmes %(browserName)s nën %(osName)s",
@ -9,7 +9,7 @@
"Dismiss": "Mos e merr parasysh", "Dismiss": "Mos e merr parasysh",
"powered by Matrix": "bazuar në Matrix", "powered by Matrix": "bazuar në Matrix",
"Welcome to Riot.im": "Mirë se vini te Riot.im", "Welcome to Riot.im": "Mirë se vini te Riot.im",
"Decentralised, encrypted chat &amp; collaboration powered by [matrix]": "Decentralised, encrypted Fjalosje &amp; bashkëpunim i decentralizuar, i fshehtëzuar, bazuar në [matrix]", "Decentralised, encrypted chat &amp; collaboration powered by [matrix]": "Fjalosje &amp; bashkëpunim i decentralizuar, i fshehtëzuar, bazuar në [matrix]",
"Search the room directory": "Kërkoni te drejtoria e dhomave", "Search the room directory": "Kërkoni te drejtoria e dhomave",
"Lots of rooms already exist in Matrix, linked to existing networks (Slack, IRC, Gitter etc) or independent. Check out the directory!": "Ka tashmë plot dhoma në Matrix, të lidhura me rrjete ekzistues (Slack, IRC, Gitter, etj) ose të pavarur. Hidhini një sy listës!", "Lots of rooms already exist in Matrix, linked to existing networks (Slack, IRC, Gitter etc) or independent. Check out the directory!": "Ka tashmë plot dhoma në Matrix, të lidhura me rrjete ekzistues (Slack, IRC, Gitter, etj) ose të pavarur. Hidhini një sy listës!",
"Chat with Riot Bot": "Fjalosuni me Robotin Riot", "Chat with Riot Bot": "Fjalosuni me Robotin Riot",
@ -27,12 +27,13 @@
"Support for those using and running matrix-appservice-irc": "Asistencë për ata që përdorin dhe xhirojnë matrix-appservice-irc", "Support for those using and running matrix-appservice-irc": "Asistencë për ata që përdorin dhe xhirojnë matrix-appservice-irc",
"Building services on Matrix": "Ndërtim shërbimesh mbi Matrix", "Building services on Matrix": "Ndërtim shërbimesh mbi Matrix",
"Support for those using the Matrix spec": "Asistencë për ata që përdorin specifikimet Matrix", "Support for those using the Matrix spec": "Asistencë për ata që përdorin specifikimet Matrix",
"Design and implementation of E2E in Matrix": "Konceptimi dhe sendërtimi i E2E në Matrix", "Design and implementation of E2E in Matrix": "Konceptimi dhe sendërtimi i E2E-s në Matrix",
"Implementing VR services with Matrix": "Sendërtim shërbimesh VR me Matrix-in", "Implementing VR services with Matrix": "Sendërtim shërbimesh VR me Matrix-in",
"Implementing VoIP services with Matrix": "Sendërtim shërbimesh VoIP me Matrix-in", "Implementing VoIP services with Matrix": "Sendërtim shërbimesh VoIP me Matrix-in",
"Discussion of the Identity Service API": "Diskutime mbi Identity Service API", "Discussion of the Identity Service API": "Diskutime mbi API-n Identity Service",
"Support for those using, running and writing other bridges": "Asistencë për ata që përdorin, xhirojnë ose programojnë ura të tjera", "Support for those using, running and writing other bridges": "Asistencë për ata që përdorin, xhirojnë ose programojnë ura të tjera",
"Contributing code to Matrix and Riot": "Kontribut me kod te Matrix dhe te Riot", "Contributing code to Matrix and Riot": "Kontribut me kod te Matrix dhe te Riot",
"Dev chat for the Riot/Web dev team": "Fjalosje mbi zhvillimin, për ekipin e zhvilluesve të Riot/Web-i", "Dev chat for the Riot/Web dev team": "Fjalosje mbi zhvillimin, për ekipin e zhvilluesve të Riot/Web-i",
"Dev chat for the Dendrite dev team": "Fjalosje zhvillimi, për ekipin e zhvilluesve të Dendrite-it" "Dev chat for the Dendrite dev team": "Fjalosje mbi zhvillimi, për ekipin e zhvilluesve të Dendrite-it",
"Co-ordination for Riot translators": "Bashkërendim për përkthyes të Riot-it"
} }

View file

@ -33,8 +33,7 @@ export async function getVectorConfig(relativeLocation) {
} }
function getConfig(configJsonFilename) { function getConfig(configJsonFilename) {
let deferred = Promise.defer(); return new Promise(function(resolve, reject) {
request( request(
{ method: "GET", url: configJsonFilename }, { method: "GET", url: configJsonFilename },
(err, response, body) => { (err, response, body) => {
@ -48,10 +47,10 @@ function getConfig(configJsonFilename) {
// from a file:// URI. // from a file:// URI.
if (response) { if (response) {
if (response.status == 404 || (response.status == 0 && body == '')) { if (response.status == 404 || (response.status == 0 && body == '')) {
deferred.resolve({}); resolve({});
} }
} }
deferred.reject({err: err, response: response}); reject({err: err, response: response});
return; return;
} }
@ -59,9 +58,8 @@ function getConfig(configJsonFilename) {
// parameter, since this throws a parse error on empty // parameter, since this throws a parse error on empty
// which breaks if there's no config.json and we're // which breaks if there's no config.json and we're
// loading from the filesystem (see above). // loading from the filesystem (see above).
deferred.resolve(JSON.parse(body)); resolve(JSON.parse(body));
} },
); );
});
return deferred.promise;
} }

View file

@ -37,6 +37,14 @@
<section id="matrixchat" style="height: 100%;"></section> <section id="matrixchat" style="height: 100%;"></section>
<noscript>Sorry, Riot requires JavaScript to be enabled.</noscript> <!-- TODO: Translate this? --> <noscript>Sorry, Riot requires JavaScript to be enabled.</noscript> <!-- TODO: Translate this? -->
<% for (var i=0; i < htmlWebpackPlugin.files.js.length; i++) { <% for (var i=0; i < htmlWebpackPlugin.files.js.length; i++) {
if (_.endsWith(htmlWebpackPlugin.files.js[i], 'olm.js')) {
var array = htmlWebpackPlugin.files.js;
htmlWebpackPlugin.files.js.unshift(htmlWebpackPlugin.files.js[i]);
htmlWebpackPlugin.files.js.splice(i, 1);
}
}
for (var i=0; i < htmlWebpackPlugin.files.js.length; i++) {
// Not a particularly graceful way of not putting the indexeddb worker script // Not a particularly graceful way of not putting the indexeddb worker script
// into the main page // into the main page
if (_.endsWith(htmlWebpackPlugin.files.js[i], 'indexeddb-worker.js')) { if (_.endsWith(htmlWebpackPlugin.files.js[i], 'indexeddb-worker.js')) {
@ -73,6 +81,6 @@
</audio> </audio>
<audio id="remoteAudio"></audio> <audio id="remoteAudio"></audio>
<!-- let CSS themes pass constants to the app --> <!-- let CSS themes pass constants to the app -->
<div id="mx_theme_accentColor"></div><div id="mx_theme_secondaryAccentColor"/></div><div id="mx_theme_tertiaryAccentColor"/></div> <div id="mx_theme_accentColor"></div><div id="mx_theme_secondaryAccentColor"></div><div id="mx_theme_tertiaryAccentColor"></div>
</body> </body>
</html> </html>

View file

@ -62,6 +62,10 @@ import {getVectorConfig} from './getconfig';
let lastLocationHashSet = null; let lastLocationHashSet = null;
// Disable warnings for now: we use deprecated bluebird functions
// and need to migrate, but they spam the console with warnings.
Promise.config({warnings: false});
function initRageshake() { function initRageshake() {
rageshake.init().then(() => { rageshake.init().then(() => {
console.log("Initialised rageshake: See https://bugs.chromium.org/p/chromium/issues/detail?id=583193 to fix line numbers on Chrome."); console.log("Initialised rageshake: See https://bugs.chromium.org/p/chromium/issues/detail?id=583193 to fix line numbers on Chrome.");
@ -175,8 +179,7 @@ function makeRegistrationUrl(params) {
} }
function getConfig(configJsonFilename) { function getConfig(configJsonFilename) {
let deferred = Promise.defer(); return new Promise(function(resolve, reject) {
request( request(
{ method: "GET", url: configJsonFilename }, { method: "GET", url: configJsonFilename },
(err, response, body) => { (err, response, body) => {
@ -190,10 +193,10 @@ function getConfig(configJsonFilename) {
// from a file:// URI. // from a file:// URI.
if (response) { if (response) {
if (response.status == 404 || (response.status == 0 && body == '')) { if (response.status == 404 || (response.status == 0 && body == '')) {
deferred.resolve({}); resolve({});
} }
} }
deferred.reject({err: err, response: response}); reject({err: err, response: response});
return; return;
} }
@ -201,11 +204,10 @@ function getConfig(configJsonFilename) {
// parameter, since this throws a parse error on empty // parameter, since this throws a parse error on empty
// which breaks if there's no config.json and we're // which breaks if there's no config.json and we're
// loading from the filesystem (see above). // loading from the filesystem (see above).
deferred.resolve(JSON.parse(body)); resolve(JSON.parse(body));
} },
); );
});
return deferred.promise;
} }
function onTokenLoginCompleted() { function onTokenLoginCompleted() {

View file

@ -68,11 +68,11 @@ export default class WebPlatform extends VectorBasePlatform {
// annoyingly, the latest spec says this returns a // annoyingly, the latest spec says this returns a
// promise, but this is only supported in Chrome 46 // promise, but this is only supported in Chrome 46
// and Firefox 47, so adapt the callback API. // and Firefox 47, so adapt the callback API.
const defer = Promise.defer(); return new Promise(function(resolve, reject) {
global.Notification.requestPermission((result) => { global.Notification.requestPermission((result) => {
defer.resolve(result); resolve(result);
});
}); });
return defer.promise;
} }
displayNotification(title: string, msg: string, avatarUrl: string, room: Object) { displayNotification(title: string, msg: string, avatarUrl: string, room: Object) {
@ -103,13 +103,13 @@ export default class WebPlatform extends VectorBasePlatform {
} }
_getVersion(): Promise<string> { _getVersion(): Promise<string> {
const deferred = Promise.defer();
// We add a cachebuster to the request to make sure that we know about // We add a cachebuster to the request to make sure that we know about
// the most recent version on the origin server. That might not // the most recent version on the origin server. That might not
// actually be the version we'd get on a reload (particularly in the // actually be the version we'd get on a reload (particularly in the
// presence of intermediate caching proxies), but still: we're trying // presence of intermediate caching proxies), but still: we're trying
// to tell the user that there is a new version. // to tell the user that there is a new version.
return new Promise(function(resolve, reject) {
request( request(
{ {
method: "GET", method: "GET",
@ -119,15 +119,15 @@ export default class WebPlatform extends VectorBasePlatform {
(err, response, body) => { (err, response, body) => {
if (err || response.status < 200 || response.status >= 300) { if (err || response.status < 200 || response.status >= 300) {
if (err === null) err = { status: response.status }; if (err === null) err = { status: response.status };
deferred.reject(err); reject(err);
return; return;
} }
const ver = body.trim(); const ver = body.trim();
deferred.resolve(ver); resolve(ver);
}, },
); );
return deferred.promise; });
} }
getAppVersion(): Promise<string> { getAppVersion(): Promise<string> {

View file

@ -30,29 +30,40 @@ module.exports = {
"theme-status": "./res/themes/status/css/status.scss", "theme-status": "./res/themes/status/css/status.scss",
}, },
module: { module: {
preLoaders: [ rules: [
{ test: /\.js$/, loader: "source-map-loader" }, { enforce: 'pre', test: /\.js$/, use: "source-map-loader", exclude: /node_modules/, },
], { test: /\.js$/, use: "babel-loader", include: path.resolve(__dirname, 'src') },
loaders: [
{ test: /\.json$/, loader: "json" },
{ test: /\.js$/, loader: "babel", include: path.resolve('./src') },
{ {
test: /\.scss$/, test: /\.scss$/,
// 1. postcss-loader turns the SCSS into normal CSS. // 1. postcss-loader turns the SCSS into normal CSS.
// 2. css-raw-loader turns the CSS into a javascript module // 2. raw-loader turns the CSS into a javascript module
// whose default export is a string containing the CSS. // whose default export is a string containing the CSS.
// (css-raw-loader is similar to css-loader, but the latter // (raw-loader is similar to css-loader, but the latter
// would also drag in the imgs and fonts that our CSS refers to // would also drag in the imgs and fonts that our CSS refers to
// as webpack inputs.) // as webpack inputs.)
// 3. ExtractTextPlugin turns that string into a separate asset. // 3. ExtractTextPlugin turns that string into a separate asset.
loader: ExtractTextPlugin.extract("css-raw-loader!postcss-loader?config=postcss.config.js"), use: ExtractTextPlugin.extract({
use: [
"raw-loader",
{
loader: 'postcss-loader',
options: {
config: {
path: './postcss.config.js'
}
}
}
],
}),
}, },
{ {
// this works similarly to the scss case, without postcss. // this works similarly to the scss case, without postcss.
test: /\.css$/, test: /\.css$/,
loader: ExtractTextPlugin.extract("css-raw-loader"), use: ExtractTextPlugin.extract({
use: "raw-loader"
}),
}, },
], ],
noParse: [ noParse: [
// for cross platform compatibility use [\\\/] as the path separator // for cross platform compatibility use [\\\/] as the path separator
@ -152,6 +163,12 @@ module.exports = {
// don't fill the console up with a mahoosive list of modules // don't fill the console up with a mahoosive list of modules
chunks: false, chunks: false,
}, },
// hot mdule replacement doesn't work (I think we'd need react-hot-reload?)
// so webpack-dev-server reloads the page on every update which is quite
// tedious in Riot since that can take a while.
hot: false,
inline: false,
}, },
}; };