Commit Graph

335 Commits (e9bb92c4da5636367bfaade6dbf7d3c5e12c17af)

Author SHA1 Message Date
Scott Nonnenberg d97a7eabf8 v1.15.0-beta.1 7 years ago
Scott Nonnenberg 3c69886320 Finish new Message component, integrate into application
Also:
- New schema version 8 with video/image thumbnails, screenshots, sizes
- Upgrade messages not at current schema version when loading messages
  to show in conversation
- New MessageDetail react component
- New ConversationHeader react component
7 years ago
Scott Nonnenberg 43a44793c5 Remove jshint - move everything over to eslint
Also removed all hints of previous linters
7 years ago
Scott Nonnenberg a689d430d2 v1.14.1-beta.1 7 years ago
Scott Nonnenberg d014fa779e v1.14.0-beta.3 7 years ago
Scott Nonnenberg 9b04c8ecf3 v1.14.0-beta.2 7 years ago
Scott Nonnenberg 8776b376f6 Ensure that the production build has permissions_popup_preload.js 7 years ago
Scott Nonnenberg b385489a44 v1.14.0-beta.1 7 years ago
Scott Nonnenberg ad4387803b New media permission, show dialog when not enabled for voice msg
UI now in separate renderer:
  - the permissions popup
  - settings dialog
  - debug log dialog
  - about window

Couple bug fixes:
  - About Window: Fix 'escape' to close window
  - Remove outdated dist/copy tasks from Gruntfile

Eslintified settings_view.js
7 years ago
Scott Nonnenberg e83e10a7d1
Include about_preload.js in production builds (#2485) 7 years ago
Scott Nonnenberg bd13939548 v1.13.0-beta.2 7 years ago
Scott Nonnenberg 8eeaad8e18 Remove unused export/import functionality 7 years ago
Scott Nonnenberg 4ccddeaccc v1.13.0-beta.1 7 years ago
Scott Nonnenberg 6dd93271d9 v1.12.0-beta.2 7 years ago
Scott Nonnenberg 41c8dbc4f9 v1.12.0-beta.1 7 years ago
Scott Nonnenberg ec3e36824c Remove jscs from the project 7 years ago
Scott Nonnenberg cfe0bd0e79 Move to npm for several dependencies
mustache
jQuery
underscore
backbone
mocha
chai
intl-tel-input
7 years ago
Scott Nonnenberg 2988da0981 Turn on all of Microsoft's recommend lint rules
Biggest changes forced by this: alt tags for all images, resulting in
new strings added to messages.json, and a new i18n paramter/prop added
in a plot of places.

Another change of note is that there are two new tslint.json files under
ts/test and ts/styleguide to relax our rules a bit there. This required
a change to our package.json script, as manually specifying the config
file there made it ignore our tslint.json files in subdirectories
7 years ago
Scott Nonnenberg 91c247ef8d Move all forks to @scottnonnenberg-signal account 7 years ago
Scott Nonnenberg e02887565b
Update to electron v2.0.1 (#2401)
* Remove extra parenthesis causing warnings on latest chromium

* Update to electron 2.0.1

* Move all @types dependencies to devDependencies

* Update electron-builder/electron-updater

* Update to Node.js 8.9.3 to match Electron 2.0.1
7 years ago
Scott Nonnenberg 877cbfc338 v1.11.0-beta.5
Fix broken CSP
7 years ago
Scott Nonnenberg e52c7ca2f3 v1.11.0-beta.4
Move to react for newlines, emoji, and links in message body
7 years ago
Scott Nonnenberg 4e5c8965ff Move to react for newlines, emoji, and links in message body 7 years ago
Scott Nonnenberg 721935b0c8 v1.11.0-beta.3
Update link handling
7 years ago
Scott Nonnenberg d8e0a489b2 v1.11.0-beta.2
Notification Improvements (#2364)
  - Fixed: The change for production didn't full make it into v1.11.0-beta.1 - this change restores the code which removes the old notification when we add a new one
  - Fixed: Notifications could be orphaned in notification center if they were added/removed quickly
  - Fixed: Notifications weren't removed properly when read on a linked device

Dev: Better logging when we receive a read sync from a linked device (#2364)
7 years ago
Scott Nonnenberg d9685178d2 v1.11.0-beta.1
Feature: Receive contact (#2349, #2359)

Fixed: Sometimes clicks on quoted message wouldn't work (#2350)

Fixed: In dark theme, it was hard to see a message's triple-dot menu on hover - thanks @PunkChameleon (#2334)

Fixed: Unsupported image and video types were missing from media pane (#2351)

Fixed: On small screens, the media lightbox view would show media off-screen (#2351)

Notification improvements
  - Remove all on remote read, on focus, on exit
  - Show multi-message notifications like '5 new messages'

Media Gallery: A number of small visual fixes (#2351)

Emoji pane: Can now dismiss it by pressing escape key - thanks @tommypacker (#2354, #2357)

Update translations (#2328, #2352)

Dev:
  - Windows 7: Use Electron-native notifications (#2338, #2330)
  - Improve Logging For Disappearing Messages (#2332)
  - Prettier: Continue expanding its coverage of app (#2339, #2324)
  - Document Translations Setup + Remove Unused Strings (#2329)
  - Make Protocol Buffers available to commonjs code (#2347)
7 years ago
Scott Nonnenberg 41be7f126b Visuals for embedded contacts as well as contact detail screen 7 years ago
Daniel Gasienica ba4d8952c6 Revert "Use protocol buffer module for `libtextsecure`"
This does not work with `ArrayBuffer` out of the box and will need to be
investigated and tested more before switching.

Some APIs also seemed to have changed:
- Before (OOP): `new textsecure.protobuf.WebSocketMessage(…).encode();`
- After (functional):
  ```
  textsecure.protobuf.WebSocketMessage.encode(
    new textsecure.protobuf.WebSocketMessage(…)
  );
  ```

This reverts commit d758119d9de4f99742ea941e86180b1d600c2f22.
7 years ago
Daniel Gasienica 60077d0b7b Use protocol buffer module for `libtextsecure` 7 years ago
Daniel Gasienica daa4a3d63f Compile all protocol buffers 7 years ago
Daniel Gasienica 086c64deb8 Add `yarn clean-protobuf` command 7 years ago
Daniel Gasienica 55f85465c6 Remove generated protobuf as part of `yarn clean-transpile` 7 years ago
Daniel Gasienica cb09da0f63 Run all build steps in CI 7 years ago
Daniel Gasienica 2d95745d56 Add `yarn build-protobuf` command 7 years ago
Daniel Gasienica 58399549c3 Add `protobufjs` dependency 7 years ago
Daniel Gasienica 8ee250d37e Prettier: Format CSS, SCSS, and JSON 7 years ago
Daniel Gasienica 38b23c6627 Add `@types/semver` 7 years ago
Daniel Gasienica 0b4c60c272 Add `@types/sinon` 7 years ago
Daniel Gasienica e3191c9017 Remove `node-notifier` 7 years ago
Scott Nonnenberg 754d65ae2e Let's make it all pretty, shall we?
We missed a couple directories with previous attempts to turn this on
globally: app/ and libtextsecure/

Not to mention files in places we didn't expect: ts files that weren't
in the ts directory!

This turns prettier on for every file we care about (js, ts, tsx, md)
everywhere in the project but for a few key parts.
7 years ago
Scott Nonnenberg 322d307655 Turn on prettier support for markdown files, update all files 7 years ago
Scott Nonnenberg cea77418ec Remove unused asarl package.json script, rearrange a little 7 years ago
Scott Nonnenberg 167f54f37f Remove unused build assets
Linux: deb (dropped zip)
Mac: zip (dropped dmg)
Windows: exe (dropped zip)

We can always re-add if people are relying on these things. But our
download links all point to these assets, so we'll generate and upload
only these for now.
7 years ago
Scott Nonnenberg 58fddc4e9d Remove electron builder support for publishing to S3
We do this ourselves now.
7 years ago
Scott Nonnenberg 50eb82fa6a package.json: Remove all but the scripts needed for modern build 7 years ago
Scott Nonnenberg af94c67e42 v1.10.0-beta.1
Media Gallery showing all attachments in a given conversation (#2291, previous: #2236)

Quotes:
  - Show 'You' in Android theme instead of your own contact name (#2312)
  - Show thumbnails for quotes of messages with video attachments (#2293)

Video attachments: show first frame preview in composition area (#2293)

Increase speed of migration to move attachments to disk from database (#2314)

Dev:
  - Add comments clarifying our mechanisms for stripping EXIF info (#2313)
  - Move to prettierjs to format our code (#2303)
  - Fix break in styleguide; make filesize/Signal.Util.GoogleChrome available (#2302)
  - Remove duplicate entry from .gitignore (#2271)
7 years ago
Daniel Gasienica 522bd57ec3 Run `yarn lint-windows` without Prettier for AppVeyor
We need to figure out how to run globs on Windows.
7 years ago
Daniel Gasienica 1d867d784d Decouple `yarn format` from `yarn format-check`
Checking if that fixes Windows CI issue.
7 years ago
Daniel Gasienica 428984c8e2 Include Prettier as part of `yarn lint` 7 years ago
Daniel Gasienica 97dfffd2b0 Add `.prettierrc.js` 7 years ago
Daniel Gasienica aa7665e497 Run Prettier on all source files 7 years ago
Daniel Gasienica 1bf3ab630c Add `eslint-config-prettier` 7 years ago
Scott Nonnenberg b9b85a0030
v1.9.0-beta.1
Send quoted replies via hover menu on message (#2284, #2292)

Fixed: Linking a new iOS device would not initially show iOS theme (#2284)

Fixed: In iOS theme, narrow images would result in a broken chat bubble (#2273, #2282)

Dev:
  - Fix beta install instructions in readme for debian-based linux (#2262)
  - Media Gallery: Phase 1 - currently disabled (#2236)
7 years ago
Daniel Gasienica 5ec8b1c6e1 Add `@types/jquery` 7 years ago
Daniel Gasienica dea56c0008 Autoformat TSX files 7 years ago
Daniel Gasienica 2fae89f0e8 Add trailing commas to autoformatted code 7 years ago
Daniel Gasienica 347fc8287a Add `yarn format` to autoformat code
Uses Prettier under the hood. Requires opt-in via `@prettier` pragma:
https://prettier.io/docs/en/options.html#require-pragma
7 years ago
Daniel Gasienica 56a5006392 Remove duplicate `@types/lodash` dependency 7 years ago
Daniel Gasienica 3a8c3ccdab Add `prettier` 7 years ago
Daniel Gasienica 8ef04cb1fd Move `@types/*` dependencies to `devDependencies` 7 years ago
Daniel Gasienica 10bede85c9 Add `filesize` dependency 7 years ago
Daniel Gasienica 9533c09707 Add `@types/lodash` 7 years ago
Scott Nonnenberg a7d44d3344
Backup and end-to-end test! 7 years ago
Scott Nonnenberg 3dbc550db2
v1.8.0-beta.1
Receive quoted replies (#2244)

iOS theme: one bubble for both attachment and message contents (#2244)

Improve URL Auto-Linking In Messages (#2240)

Redact More Variants Of Paths In Stack Traces (#2229)

Fixed: Conversation message preview would sometimes continue to show after message disappeared (1206b3c448)

Dev: Introduce React, TypeScript, TSLint and React-StyleGuidist (#2219 and #2232)
7 years ago
Scott Nonnenberg 21bf02c94d
Fixed examples in Quote.md, rough Android visuals 7 years ago
Daniel Gasienica 560cc4e149 Set dynamic parameter last 7 years ago
Daniel Gasienica 9d159da79c Add Microsoft contributed TSlint rules: `tslint-microsoft-contrib` 7 years ago
Daniel Gasienica 55fc21505e Rename `ts/test` to `ts/styleguide` 7 years ago
Daniel Gasienica 99dbdc3506 Include compiled TypeScript JavaScript files in build 7 years ago
Daniel Gasienica d6436de3bd Organize npm scripts
Combine `yarn grunt jshint` and `yarn grunt jscs` into `yarn grunt lint`.
7 years ago
Daniel Gasienica 6f4d0e1449 Use project for TSLint 7 years ago
Daniel Gasienica 15d221ae0e Simplify testing and linting
Separate linting from testing as follows:

- `yarn jscs`: Run JSCS.
- `yarn jshint`: Run JSHint.
- `yarn lint`: Run all linters, i.e. ESLint, TSLint, JSHint, and JSHint.

- `yarn test-node`: Run Mocha tests in Node.js environment.
- `yarn test-electron`: Run tests in Electron environment via Grunt.
- `yarn test`: Run all tests.

CI
- Align Travis and AppVeyor scripts as much as possible.
- Run linting before tests to fail fast.
- Run Node.js (headless and fast) tests first.
- Run Electron tests last (Travis seems to require custom setup in `travis.sh`).
7 years ago
Daniel Gasienica d6b40a3e94 Explicitly point to TSLint configuration
AppVeyor seems to ignore our configuration.
7 years ago
Daniel Gasienica 9d41b86162 Remove escaping from `linkText`
We leverage jQuery’s HTML escaping in `$.html(…)`.
7 years ago
Daniel Gasienica d9381c543e Add `linkify-it` dependency 7 years ago
Daniel Gasienica 7d4ef9315b Add `yarn test-ts` 7 years ago
Daniel Gasienica 6f8dee402d Add `@types/mocha` 7 years ago
Daniel Gasienica 7ac4bee959 Add `@types/chai` 7 years ago
Daniel Gasienica 78ba4eddc1 Add `@types/lodash` 7 years ago
Daniel Gasienica f5641fe6d6 Add `link-text` dependency
It only has the minimum required dependencies:
- `linkify-it`: Best-in-class link detection library with support for
                Unicode/IDN.
- `escape-html`: Standalone dependency for escaping HTML.
- `uc.micro`: Standalone dependency of Unicode data files.
7 years ago
Scott Nonnenberg c6c3b65bbc
Introduce React, TypeScript, TSLint and React-StyleGuidist (#2219)
Quite a bit of change here.

First, the basics:

- New dependencies were added: react, typescript, tslint, and react-styleguidist
- A new npm script: transpile. It uses typescript to process .tsx files in js/react, putting .js files next to the original file. It's part of the watch functionality of grunt dev as well as the default task run with just grunt (used to build the app prior to release). A lighter-weight to get watch behavior when just working on React components is to run yarn transpile --watch.
- yarn run clean-transpile will remove generated .js files


Style guide via react-styleguidist. Example site: https://react-styleguidist.js.org/examples/basic/

- Start with yarn styleguide
- Component.md files right next to the .tsx file
- jsdoc-style comments are picked up and added to the generated part of the styleguide - the overall summary and a table listing methods and properties of the component
- It has hot-reloading!
- It uses webpack, which means that our app now pulls in webpack though we don't use it to generate anything for the production app.
- I did a bunch of work to enable the use of Backbone views in this context, which will allow us to move smoothly from the old world to the new. First, add all the permutations in the old way, and then slowly start to re-render those same views with React.

A bit of dependency cleanup to enable use in React components:

- moment was moved from our Bower dependencies to our npm dependencies, so it can be used in React components not running in a browser window.
- i18n was moved into the new commonjs format, so it can be used in React components even if window is not available.

Lastly, a bit of Gruntfile cleanup:

- Removal of Chrome App-era modifications of background.js
- Make jshint/jscs watch more targeted, since more and more we'll be using other tools
7 years ago
Scott Nonnenberg 23537546fe
Big refactor: ts/ directory for all typescript, including react
Split out test-specific and general utility react components too.

And moved our test/legacy* files for the Style Guide into a styleguide/
subdirectory of test/.

I think we'll be able to live in this directory structure for a while.
7 years ago
Scott Nonnenberg 1052341d79
Fix tslint errors and add tslint to CI task in package.json 7 years ago
Scott Nonnenberg be91a89d68
Parse theme from querystring, put on util. Moment from require()
We also fully set up i18n and put it on util as well as making
it available on windows.i18n for Backbone views.
7 years ago
Scott Nonnenberg ef6a0c1162
v1.7.0-beta.3
Update to electron 1.8.4 (#2186)

Migrate all attachments from IndexedDB to file system in the background (#2208, #2193, #2165, #2162, #2129)

Save attachments to disk when importing Chrome app export (#2212)

Fixed: Read receipts setting would not be synchronized along with re-link (#2218)

Fixed: Clicking conversation in left pane when already selected would remove focus on message composition field - thanks
@colefranz! (#2032)

Fixed: Searching for the phone number of an existing contact, then selecting 'start conversation' would erase contact details (#2191)

Fixed: Selecting Settings menu option multiple times would open multiple instances of settings view - thanks @navdeepsinghkhalsa (#2167)

Dev:
  - Relax Node.js version requirements (#2203)
  - Fix a few typos in documentation - thanks @Vinnl (#2171)
  - Update issue template to mention that translation should be via Transifex (#2157)
7 years ago
Scott Nonnenberg 1326b26585
Full styleguide now available via `yarn styleguide`
Due to a number of hacks, the style guide can be used to show Backbone
views. This will allow a smooth path from the old way of doing things to
the new.
7 years ago
Scott Nonnenberg 893fb1cb9e
Introduce React/TypeScript/TSLint into app for new UI components
npm run transpile
  Works on files under js/react/
  Outputs files right next to the .tsx file

This is part of our `grunt dev` task, as well as the default grunt task,
which does everything else necessary to get a raw git checkout ready to
run.
7 years ago
Scott Nonnenberg 1ad2b080c8
Move moment from bower deps to npm deps 7 years ago
Daniel Gasienica 29832c445a Add `@sindresorhus/is` dependency
This will allow us to do runtime and, once we have TypeScript support,
compile-time type checks.
7 years ago
Daniel Gasienica 7d0871ee0e Run tests using `yarn` instead of `npm` 7 years ago
AJ Jordan 81ac6a9031
Don't lock the Node version so strictly
This is particularly problematic because Yarn apparently
errors (not warns) if the engine doesn't match.
7 years ago
Scott Nonnenberg 4e6d1e128f
Update to electron 1.8.4 (#2186) 7 years ago
Daniel Gasienica 7eaa6ef2f7 Remove `string-to-arraybuffer` dependency
The function is simple enough to inline and this allows us to reduce our
dependencies surface area.
7 years ago
Daniel Gasienica 232e906650 Remove `tmp` as dev dependency 7 years ago
Daniel Gasienica 19a70ad8b8 Add `to-arraybuffer` dependency
Used for converting Node.js buffers to `ArrayBuffer`.
7 years ago
Daniel Gasienica 0fc2868f0e Remove `tempy` dependency
We already use `tmp`.
7 years ago
Daniel Gasienica 14f58281bc Add `string-to-array-buffer` as dev dependency
Used for testing attachment data migration.
7 years ago
Daniel Gasienica 925ddbd7db Add `tempy` as dev dependency
Useful for creating random temporary directories for testing.
7 years ago
Daniel Gasienica 14422652c6 Add `fs-extra` as direct dependency
Allows us to use `fs` with promises. Turns out it’s already a
transitive dependency.
7 years ago
Scott Nonnenberg 0d105fc190
1.7.0-beta.2
Fixed: White block at bottom of conversation panel in iOS theme
(#2144 and #2153)

Fixed: Would attempt to rotate signed prekey every five seconds,
forever, after app discovers it is unlinked
(1c6d91b59c)

Dev:
  - Introduce IndexedDB index on `messages` store tracking
    `schemaVersion` (#2128)
  - Preparation for encrypted backups
    (cea42bde7d)
  - Updates to structure of exported data - messages.zip, flat list of
    attachments (6d8f4b7b6e)
7 years ago