Skip to content

Commit

Permalink
Master (#1)
Browse files Browse the repository at this point in the history
* Show notification for non focused rooms

* Ignore **/.meteor/dev_bundle

* Close RocketChat#3783; Allow guest users to view joined direct rooms

* Slackbridge-import

* SlackBridge Import working with files now

* no message

* Add extention to filename if not included in download file (RocketChat#3914)

* Closes RocketChat#3183

* Use mime-types npm package for mime2ext

* refactor code

* Closes RocketChat#3937; Prevent selfmade notifications

* Added crowd integration (RocketChat#3852)

* Added crowd integration

* eslint fixes

* Added test connection, fixed some issues

* Addition of location share feature (RocketChat#3924)

* added new mapview package, added code to handle location share button

* added rocketchat:mapview to active packages

* updates to MapView package to support google static maps

* updated link target to blank page

* changed location button to depend on settings

* corrected eslint, changed var names

* updates to settings code

* changed maps link to navigate link for android+ios support

* stripped trailing spaces

* moved mapview files into subfolders under package

* added focus event back to location button

* add i18n entries to en file, update settings with i18n keys

* add modal confirmation of location share, moved location to geojson property under the Message model

* https://docs.mongodb.com/manual/core/2dsphere/ -> 2dsphere indexes are sparse by default and ignores the sparse: true option.

* button depends on location API being available. Tested in Chrome, Chrome Mobile, and Cordova Rocket.Chat from Store.

* Removed unnecessary translations

* Bump appVersion

* update default setting for file upload types

* fix for issue RocketChat#3953

* Tweaked markdown regex for [text](URI) to ignore close parethesis characters inside the URI

* Fix regression of iFrame login

* Fix link "go to message" on emails

- Gets the link based on room type using user's subscription data
- Do not loop over subscriptions for rooms without custom link

* Improve geolocation button

* Fix video record regex

* Closes RocketChat#3771; Fix some oembed issues

* Remove package mdg:geolocation

* Bugfix: Could not login when the CROWD disabled and LDAP enabled (RocketChat#3974)

* Prevent last admin removal (RocketChat#3971)

* More admin checks

# Conflicts:
#	packages/rocketchat-lib/server/methods/insertOrUpdateUser.coffee

* missing server side validation

# Conflicts:
#	packages/rocketchat-ui-flextab/flex-tab/tabs/userEdit.coffee

* Remove last admin check for removeUserFromRoom

* Move and fix last admin check for role removal

Check was on change admin status method, but that didn’t catch direct removal of user from role admin view.

* Fix last admin check for insert/update/delete user

Was checking if only one admin but not if the updated user was admin, preventing all updates.

* Allow translation of last admin error

* Fix assigning admin permission bypass

* Update side-nav with room counts (RocketChat#3967)

* update side-nav with room counts

* removed unused styles

* Revert "Tweaked markdown regex for [text](URI) to ignore close parentheses" (RocketChat#3976)

* Fix livechat webhook infinite retries

* Fix translation (leave it)

leave: zostaw -> opuść

* Ldap merge users (RocketChat#3992)

* Allow merge users from ldap

* Fix last commit, do not override userData in ldap sync

* Fix using cache in develop

* Fix message input flex model (RocketChat#3986)

@RocketChat/core

Closes RocketChat#3900

* Add online count in rooms member list

* Add error handling for stat server request

* Add bot-helpers package (RocketChat#3799)

* Add bot-helpers package

Hubots can query user collections through provided methods

* Update bot-helpers package

Fixes codacy issues

* Disable bot-helpers package by default

* Add settings for botHelpers user fields access

* Refactor botHelpers to use setting, validate user

* Add errors when bot requests don’t have permission

* Move settings call outside class for method

* Remove status from bot helper setting, is implicit

* Remove bot helper setting logging

* Move geolocation function to outside template

* Change the message input buttons layout

* Show guest name as message alias

* Add font family configuration

* Change main fonts

* removed text shadows

* remove height calculation

* Load and clear some cache on login

* version bump to 0.37.0

* Fix eslint

* Fix admin option of type select

* Sllow deletion of records with same id

* added uyghur translation for rocketchat-lib

* added uyghur translation for rocketchat-lib

* Fixed Not showing upload button on safari

* Fix slackbridge import and slack importer ids conflict

* Make slackbridge-import import from begin to end;
Suppress message-pinned notification from import;
Fix bug in _id generation for importer;

* livechat office hours

* changed time check from every second to every minute

* style fixes

* Init Iframe integration

* more fixes

* Fix eslint issues

* fixes

* fixes

* more style changes

* more style changes

* more style changes

* checked for uyghur translation's syntax errors

* Fix livechat branding over options button

Closes RocketChat#4030

* LingoHub Update 🚀

Manual push by LingoHub User: Gabriel Engel.
Project: Rocket.Chat

Made with ❤️ by https://lingohub.com

* fix syntax

* LingoHub Update 🚀

Manual push by LingoHub User: Gabriel Engel.
Project: Rocket.Chat

Made with ❤️ by https://lingohub.com

* Improvements to pinned items

* added globals comment as recomended by sampaiodiego

* added comments to office hour model methods

* removed trailing spaces

* test why build fails part1

* add model back in for test

* fixed lint errors

* version bump to 0.37.1

* fixed filename typo

* handle locations when disabled

* update to depend only on the gMaps API key, add i18n strings

* Add global event `unread-changed-by-subscription`

* Formatting and adding some missing permissions to standard roles

* Added File Uploaded text on attachments to i18n

* Check timestamp before notifying users

* improved ts diff function

* Set message.ts if empty

* update moment locales

* Improvements/login and registration (RocketChat#4073)

* Remove uncessary log

* Refactor login/registration code

* New setting to add custom translations

* Add option to not require password confirmation on signup

* Add Custom Fields for registration

* Closes RocketChat#4036; Do nore remove roles when editing user data

* Add arrow to indicate fields of type select

* Improve lazy loading of custom fields and translations

* Fix multiple notifications (closes RocketChat#3517) (RocketChat#4074)

* Fix multiple notifications (resolve RocketChat#3517) and close after click

* Fix replacing notification for different messages from the same room

* Added option to populate Rocket Chat with LDAP users (import them) (RocketChat#4054)

* Added option to populate Rocket Chat with LDAP users (import them)

* fix syntax

* LingoHub Update 🚀

Manual push by LingoHub User: Gabriel Engel.
Project: Rocket.Chat

Made with ❤️ by https://lingohub.com

* Action links improvements

- Adds a default style to buttons
- Remove <meta> tag from message

* Make sure Sandstorm.notify is always called for DMs

* Try to work around bug with identity being saved/restored

* Fix the verbs in Sandstorm activity events

* Fix offering Sandstorm grains without a title

* Eslint fixes

* Tweak Sandstorm activity event text

* Fix mispelling for seriliazedDescriptor

* Updated loginform a11y and UX - labels instead of placeholders (RocketChat#4075)

* Use label for select fields in registration form

* Add the timer for disconnecting, one minute after going in the background it'll disconnect

* Open room correctly after creation and new messages

* Change push gateway and stats server address

* Set gitlabs scope to 'api', the only support scope.

Fixes RocketChat#3987

* Update to Autolinker.js 0.28.0

* Less borders (RocketChat#4101)

* Removing border-bottom

* Removing border-bottom

* remove shadow rom buttons

* move colours to the correct file

* removed side margins around buttons

* Changes rtl check in ChatMessages class (RocketChat#4049)

* Added view-d-room to guest role

So they can see direct messages.

* valueChanged optimization

valueChange checks if the text is rtl or ltr on every input, changed the method to check only the first input.

* Update startup.coffee

* Fixes pr RocketChat#4049

fixes the value.lenght to value.length and used the this.value instead of the value in the parameter

* Update chatMessages.coffee

* Update startup.coffee

* Update startup.coffee

* Improve stream broadcast connection (RocketChat#4119)

* Renaming files (RocketChat#4118)

* moving from coffee to js

* renaming method

* Add Ubuntu 16.04-under 30 seconds snap deployment

* Add Ubuntu App Explorer link for 30 second deploy

-  added official app explorer link + logo
-  fixed link from ToC
-  fixed XMPP bridge link

* createPrivateGroup method

* Standardized thrown errors

* Moved createPrivateGroup to rocketchat-lib

* Fixes RocketChat#4121 ModelsBase.update throws error when using array update operators

* fixed buttons margins and upload file list

* Fixing buttons margins

* Fixing buttons margins

* Slackbridge refactoring

* Add role to disable/enable channel preview (RocketChat#4127)

* Add role to disable/enable channel preview

* Add message to inform user

* Add room setting to require code to join Room (RocketChat#4126)

* Fix scoped permission verification when no scope passed

* Refactor room settings

* Add room setting to require code to join

* Initial work on getting the smarsh connector wired up. livechat package disabled for now, will enable it again (disabled for build speed)

* New and unique loading

* Fix loading of mizzao’s package

* Fix eslint errors

* Smarsh connector work/Message History.

This will send emails the configured email address with a table of all messages from all the different rooms, including direct messages.Each room will be a different email sent.
Files uploaded will be attached to the email IF and ONLY IF the uploads are to the database or the file system.

* Add the livechat packages back in

* LingoHub Update 🚀

Manual push by LingoHub User: Gabriel Engel.
Project: Rocket.Chat

Made with ❤️ by https://lingohub.com

* Fix the incorrectly spelled word and also defer the execution to be async, for the smarsh items

* The update of insertOrUpdate doesn't do anything with roles, no need to check there for last admin

* Change the wording of the embed description

* Refactoring

* Don't send offline emails to users who aren't active

* Fix user update check for last admin

* Reenabled user avatar

* Fix missing semicolong

* Do not check for last admin while updating a user

* version bump to 0.38.0

* Tweak SandstormOembed styling/format

Remove the "Click to open grain" text and make the title look like a
link.

* Parameter Checks  (RocketChat#4147)

* add checks in the methods for checking if the data received in the parameters are in their correct type

* Put the checks in the start of the method and fixed some indentation

* no message

* no message

* no message

* no message

* no message

* no message

* no message

* Fix input label position and background color for autofill fields

* Fix E-Mail address in reset password form is case-sensitive (RocketChat#4158)

* Slackbridge fixes (RocketChat#4162)

* Remove double error trhow

* Fix channel name changed

* Fix not sending notifications for old messages

* Add option to silence adding users to room

* Silence adding existing users to room

* Add try/catch in set avatar to prevent timeout issues

* Save topic message in correct date/time

* Add logs

* fix server/methods/sendForgotPasswordEmail.coffee:15:15: unmatched OUTDENT

* Disable unessary fields on push settings

* Fix resize of message box on mobile when paste and send using `return` on keyboard

* Add try/catch for avoiding log of error on duplicate messages

* Fix importing errors

* Hide messages from stream while importing with SlackBridge

* Fix settings not being saved if the value was a number or boolean.

* Add the missing file, converted the coffeescript file to javascript

* Do not force string as setting value

* Fix the generateEml throwing an error when the message type isn't defined and fix a conflict of the saveSetting.coffee being added back in when it was removed

* Update the opened livechat room by token

* Support jitsi message types in the smarsh connector

* Fix an exception occuring in the smarsh connector when a user didn't have an email, adds a setting to configure the default email for missing emails

* Make the smarsh time format more aligned with the example provided.

* Add image attachment support when a bot (ex using giffy) posts just an image

* Accept username from SAML response

Closes RocketChat#4177

* Fix login font issues

* Change 'go to message' button style

* UI improvements to login screen

* Add roles user to slackbridge imported users

* Oops fixed dumb error

* Enable debug of push lib when debug setting is true

* Adds Support for  phabricator oauth server.

* added commentary

* fix syntax

* Add function unarchiveRoom to package.js

* Add setting to disable LDAP fallback to default account system

* Fix error with CustomOAuth on startup

* version bump to 0.39.0

* HTML-escape user data when storing in Meteor Error

* HTML-escape username when storing in Meteor Errors
  • Loading branch information
syzer committed Sep 9, 2016
1 parent 469d37b commit afd5a86
Show file tree
Hide file tree
Showing 1,982 changed files with 127,075 additions and 33,994 deletions.
32 changes: 32 additions & 0 deletions .docker/develop/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
FROM rocketchat/base

ENV RC_VERSION develop

MAINTAINER [email protected]

VOLUME /app/uploads

RUN set -x \
&& curl -SLf "https://rocket.chat/releases/${RC_VERSION}/download" -o rocket.chat.tgz \
&& curl -SLf "https://rocket.chat/releases/${RC_VERSION}/asc" -o rocket.chat.tgz.asc \
&& gpg --verify rocket.chat.tgz.asc \
&& tar -zxf rocket.chat.tgz -C /app \
&& rm rocket.chat.tgz rocket.chat.tgz.asc \
&& cd /app/bundle/programs/server \
&& npm install \
&& npm cache clear

USER rocketchat

WORKDIR /app/bundle

# needs a mongoinstance - defaults to container linking with alias 'mongo'
ENV MONGO_URL=mongodb://mongo:27017/rocketchat \
HOME=/tmp \
PORT=3000 \
ROOT_URL=http://localhost:3000 \
Accounts_AvatarStorePath=/app/uploads

EXPOSE 3000

CMD ["node", "main.js"]
32 changes: 32 additions & 0 deletions .docker/latest/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
FROM rocketchat/base

ENV RC_VERSION latest

MAINTAINER [email protected]

VOLUME /app/uploads

RUN set -x \
&& curl -SLf "https://rocket.chat/releases/${RC_VERSION}/download" -o rocket.chat.tgz \
&& curl -SLf "https://rocket.chat/releases/${RC_VERSION}/asc" -o rocket.chat.tgz.asc \
&& gpg --verify rocket.chat.tgz.asc \
&& tar -zxf rocket.chat.tgz -C /app \
&& rm rocket.chat.tgz rocket.chat.tgz.asc \
&& cd /app/bundle/programs/server \
&& npm install \
&& npm cache clear

USER rocketchat

WORKDIR /app/bundle

# needs a mongoinstance - defaults to container linking with alias 'mongo'
ENV MONGO_URL=mongodb://mongo:27017/rocketchat \
HOME=/tmp \
PORT=3000 \
ROOT_URL=http://localhost:3000 \
Accounts_AvatarStorePath=/app/uploads

EXPOSE 3000

CMD ["node", "main.js"]
7 changes: 5 additions & 2 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
# editorconfig.org
# EditorConfig is awesome: http://EditorConfig.org

root = true

[*]
indent_style = tab
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true

[*.{js,coffee,html}]
indent_style = tab

[*.md]
trim_trailing_whitespace = false
27 changes: 27 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
public/recorderWorker.js
lib/ua-parser.min.js
private/moment-locales/
packages/autoupdate/
packages/meteor-streams/
packages/meteor-timesync/
packages/rocketchat-migrations/
packages/rocketchat-katex/client/katex/katex.min.js
packages/rocketchat-favico/favico.js
packages/rocketchat-theme/client/minicolors/jquery.minicolors.js
packages/rocketchat-emojione/generateEmojiIndex.js
packages/rocketchat-ui/lib/Modernizr.js
packages/rocketchat-ui/lib/clipboardjs/clipboard.js
packages/rocketchat-ui/lib/jquery.swipebox.min.js
packages/rocketchat-ui/lib/particles.js
packages/rocketchat-ui/lib/recorderjs/recorder.js
packages/rocketchat-ui/lib/textarea-autogrow.js
packages/rocketchat-ui/lib/customEventPolyfill.js
packages/rocketchat-ui/lib/constallation.js
packages/rocketchat-livechat/client/lib/ua-parser.js
packages/rocketchat-livechat/public/livechat.js
packages/rocketchat-livechat/public/external.js
packages/rocketchat-autolinker/lib/Autolinker.min.js
packages/rocketchat-livechat/lib/ua-parser.js
packages/rocketchat-videobridge/client/public/external_api.js
packages/rocketchat-lib/client/lib/localforage.min.js
packages/rocketchat-livechat/app/client/lib/Autolinker.min.js
137 changes: 137 additions & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,137 @@
{
"env": {
"browser": true,
"commonjs": true,
"es6": true,
"node": true,
"jquery": true
},
"rules": {
"no-multi-spaces": 2,
"no-eval": 2,
"no-extend-native": 2,
"no-multi-str": 2,
"no-use-before-define": 2,
"no-const-assign": 2,
"no-cond-assign": 2,
"no-constant-condition": 2,
"no-control-regex": 2,
"no-debugger": 2,
"no-delete-var": 2,
"no-dupe-keys": 2,
"no-dupe-args": 2,
"no-duplicate-case": 2,
"no-empty": 2,
"no-empty-character-class": 2,
"no-ex-assign": 2,
"no-extra-boolean-cast": 2,
"no-extra-semi": 2,
"no-fallthrough": 2,
"no-func-assign": 2,
"no-inner-declarations": [2, "functions"],
"no-invalid-regexp": 2,
"no-irregular-whitespace": 2,
"no-mixed-spaces-and-tabs": 2,
"no-sparse-arrays": 2,
"no-negated-in-lhs": 2,
"no-obj-calls": 2,
"no-octal": 2,
"no-redeclare": 2,
"no-regex-spaces": 2,
"no-undef": 2,
"no-unreachable": 2,
"no-unused-vars": [2, {
"vars": "all",
"args": "after-used"
}],
"no-lonely-if": 2,
"no-trailing-spaces": 2,
"complexity": [1, 31],
"space-in-parens": [2, "never"],
"space-before-function-paren": [2, "never"],
"space-before-blocks": [2, "always"],
"indent": [2, "tab", {"SwitchCase": 1}],
"comma-dangle": [2, "never"],
"keyword-spacing": 2,
"block-spacing": 2,
"brace-style": [2, "1tbs", { "allowSingleLine": true }],
"computed-property-spacing": 2,
"comma-spacing": 2,
"comma-style": 2,
"guard-for-in": 2,
"wrap-iife": 2,
"block-scoped-var": 2,
"curly": [2, "all"],
"eqeqeq": [2, "allow-null"],
"new-cap": 2,
"use-isnan": 2,
"valid-typeof": 2,
"linebreak-style": [2, "unix"],
"quotes": [2, "single"],
"semi": [2, "always"]
},
"globals": {
"_" : false,
"__meteor_runtime_config__" : false,
"AccountBox" : false,
"Accounts" : false,
"AgentUsers" : false,
"Assets" : false,
"Blaze" : false,
"BlazeLayout" : false,
"ChatMessage" : false,
"ChatMessages" : false,
"ChatRoom" : false,
"ChatSubscription" : false,
"check" : false,
"CryptoJS" : false,
"Department" : false,
"EJSON" : false,
"Email" : false,
"FlowRouter" : false,
"HTTP" : false,
"getNextAgent" : false,
"handleError" : false,
"getAvatarUrlFromUsername" : false,
"LivechatCustomField" : false,
"LivechatDepartment" : false,
"LivechatDepartmentAgents" : false,
"livechatManagerRoutes" : true,
"LivechatPageVisited" : false,
"LivechatTrigger" : false,
"Logger" : false,
"Match" : false,
"Meteor" : false,
"moment" : false,
"Mongo" : false,
"Npm" : false,
"Package" : false,
"parentCall" : false,
"Promise" : false,
"Random" : false,
"ReactiveVar" : false,
"RocketChat" : true,
"RocketChatFile" : false,
"RocketChatFileAvatarInstance": false,
"RoomHistoryManager" : false,
"s" : false,
"ServiceConfiguration" : false,
"Session" : false,
"Settings" : false,
"SHA256" : false,
"SideNav" : false,
"swal" : false,
"t" : false,
"TAPi18n" : false,
"TAPi18next" : false,
"Template" : false,
"TimeSync" : false,
"toastr" : false,
"Tracker" : false,
"Trigger" : false,
"Triggers" : false,
"UAParser" : false,
"visitor" : false,
"WebApp" : false
}
}
38 changes: 38 additions & 0 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# Contributing to Rocket.Chat

:+1::tada: First off, thanks for taking the time to contribute! :tada::+1:

The following is a set of guidelines for contributing to Rocket.Chat and its packages, which are hosted in the [Rocket.Chat Organization](https://github.com/RocketChat) on GitHub.

__Note:__ If there's a feature you'd like, there's a bug you'd like to fix, or you'd just like to get involved please raise an issue and start a conversation. We'll help as much as we can so you can get contributing - although we may not always be able to respond right away :)

## ECMAScript 2015 vs CoffeeScript

While we still have a lot of CoffeeScript files you should not create new ones. New code contributions should be in **ECMAScript 2015**.

## Coding standards

Most of the coding standards are covered by `.editorconfig` and `.eslintrc.js`.

Things not covered by `eslint`:

* `exports`/`module.exports` should be at the end of the file
* Longer, descriptive variable names are preferred, e.g. `error` vs `err`

We acknowledge all the code does not meet these standards but we are working to change this over time.

### Syntax check

Before submitting a PR you should get no errors on `eslint`.

To check your files, first install `eslint`:

```
npm install -g eslint
```

Then run:

```
eslint .
```
1 change: 1 addition & 0 deletions .github/ISSUE_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Your Rocket.Chat version: (make sure you are running the latest)
7 changes: 7 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<!-- INSTRUCTION: Keep the line below to notify all core developers about this new PR -->
@RocketChat/core

<!-- INSTRUCTION: Inform the issue number that this PR closes, or remove the line below -->
Closes #ISSUE_NUMBER

<!-- INSTRUCTION: Tell us more about your PR with screen shots if you can -->
6 changes: 4 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
**/build/*
**/node_modules/*
**/tmp/*
**/.meteor/dev_bundle
/private/certs/*
*.bak
*.iml
Expand All @@ -11,6 +12,7 @@
*.log
*.pydevproject
*.sublime-project
*.sublime-workspace
*.swp
*.tmp
*.tokens
Expand All @@ -35,7 +37,7 @@
.loadpath
.map
.metadata
.meteor/local
.meteor/local*
.meteor/meteorite
.mule
.pmd
Expand All @@ -46,7 +48,6 @@
.Trashes
.wtpmodules
\#*\#
BuildInfo.js
Desktop.ini
ehthumbs.db
example.css
Expand All @@ -67,3 +68,4 @@ tramp
ecosystem.json
pm2.json
settings.json
build.sh
2 changes: 2 additions & 0 deletions .lgtm
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
approvals = 2
pattern = "(?i)LGTM"
2 changes: 0 additions & 2 deletions .meteor/cordova-plugins

This file was deleted.

Loading

0 comments on commit afd5a86

Please sign in to comment.