Commit Graph

748 Commits

Author SHA1 Message Date
David Sevilla Martín
92c8c616e1
Use m.deferred instead of native Promise 2018-03-24 17:43:03 -04:00
David Sevilla Martín
4aad293284
Merge branch 'master' into patch-2 2018-03-21 17:02:43 -04:00
Franz Liedke
447ca18558
Recompile JavaScript 2018-03-19 23:21:57 +01:00
David Sevilla Martín
6ea60248e3
always return a promise in PostStream#update 2018-03-18 20:37:04 -04:00
AFR
1a2df2d581 FontAwesome v5.0.6 (#1372)
* Update FontAwesome to v5.0.6

* Adapt DiscussionListItem-count icon to match FontAwesome 5 syntax

* Change icon name to match FontAwesome 5.0.6 fas icon

* Add font type prefix parameter to icon helper

* Add Enable Icon Prefix to show icon in Extension Page

* Fix invalid icon behavior

* Change icon name to match FontAwesome 5.0.6 far icon

* Use iconPrefix property on component

* Use full icon class name

* Update icon helper docblock

* Full icon class syntax
2018-02-23 23:42:00 +01:00
Franz Liedke
f0cea11e79
API: Provide forum info under /
Closes #875.
2018-02-11 16:40:05 +01:00
Clark Winkelmann
a53d95a3d9
Fix jsdoc for notification types 2018-02-09 02:53:05 +01:00
Clark Winkelmann
ff10ed0ea9
Use an extendable ItemList for notification methods 2018-02-09 02:51:42 +01:00
Johann Rodríguez
7721288ac6 No slug? Then no '-' separator! (#1351)
* Stop using slug separator when there is no slug

* Changing as per upstream requirements
2018-02-09 07:22:50 +10:30
Toby Zerner
322a84f516
Improve search performance (#1339)
* Improve fulltext gambit

* Only search in visible posts

This change relies on the `visibility-scoping` branch to be merged.

* Change posts table to use InnoDB engine

Doing a JOIN between an InnoDB table (discussions) and a MyISAM table
(posts) is very very (very) bad for performance. FULLTEXT indexes are
fully supported in InnoDB now, and it is a superior engine in every
other way, so there is no longer any reason to be using MyISAM.

* Use ::class

* Only search for comment posts

* Add fulltext index to discussions.title

* Fix migration not working if there is a table prefix

* Update frontend appearance

* Apply fixes from StyleCI

[ci skip] [skip ci]

* Show search result excerpts on mobile
2018-02-08 06:38:08 +10:30
Clark Winkelmann
d357364712 Rename method and attribute, and remove unnecessary attribute filtering 2018-01-11 23:05:26 +01:00
Clark Winkelmann
26449a64fe Merge remote-tracking branch 'upstream/master' into signup-fields-locking 2018-01-11 22:54:41 +01:00
AFR
6dc96b38af Add Custom Footer HTML (#1315)
* Add Custom Footer HTML

Straight copy from Custom Header HTML

* Move Custom Footer HTML to exactly before `</body>` tag.

* Fix invalid class name

* Append CustomFooterHTML when preparing the view.

* Some consistency in placing the variable
2018-01-05 23:44:11 +01:00
Clark Winkelmann
9342723f64 Manage Composer height with overridable methods (#1272)
* Manage Composer height in a separate class with overridable methods

* Use a computed method

* Keep everything in Composer.js

* Drop usage of computed property for the Composer height
Because the Composer height also depends on the page height and is rarely called without position, height or page height changing anyway
2018-01-04 09:39:06 +10:30
Clark Winkelmann
fa9d89d690 Prevent editing fields in sign up modal according to identification data 2018-01-02 00:13:33 +01:00
Toby Zerner
77c25ab725 Add infinite scrolling in the notifications list 2017-12-13 15:28:54 +10:30
Toby Zerner
3dcfe32b27 Extract admin dashboard statistics from core into an extension 2017-12-10 21:03:48 +10:30
Sajjad Hashemian
0a654d1f31 remove autolink #1214 2017-11-30 13:38:45 +03:30
Toby Zerner
1ef9217f4d Basic implementation of dashboard widgets, statistics
Currently not user-customizable. Just needed to display statistics for a
client, so figured I'd make a start at this. Nothing too fancy for now,
but I'm sure some people will be happy to have this information at their
fingertips.
2017-11-29 17:19:20 +10:30
Toby Zerner
7796580210 Actually list users returned from the API when searching 2017-11-20 10:37:21 +10:30
Toby Zerner
55a09a2f57
Merge pull request #1261 from josephnle/drag-and-drop-avatar-upload
Add drag and drop avatar uploading
2017-11-13 01:33:29 +02:00
Toby Zerner
1a102766a9 Fix Composer textarea losing its height across route changes
There is a Mithril bug which causes context.retain to be ineffective for
children nodes. https://github.com/MithrilJS/mithril.js/issues/1300

Thus, we have to assume that the children nodes (like the textarea)
may be recreated and thus we need to update its height on each redraw.

fixes #948
2017-11-07 21:12:03 +10:30
Toby Zerner
abda11c6c5 Oops, recompile JS properly 2017-11-05 17:57:56 +10:30
Toby Zerner
b43fdec2e9 Recompile JS 2017-11-05 17:38:30 +10:30
Toby Zerner
a8826dcd88 Remove FastClick. Fixes #1268
Turns out FastClick was causing textareas to be buggy on iOS Safari,
and it wasn't really doing any good.
2017-11-05 17:32:43 +10:30
Toby Zerner
41df32f66e Add a tooltip to the Preview button 2017-11-05 16:25:34 +10:30
Toby Zerner
094345de85 Improve mobile composer behaviour
- Don't scroll to the bottom of the discussion when selecting "Reply"
  from the menu if the composer is in full screen mode (ie. on mobile).
  ref #1271

- After posting a reply, scroll to the end of the discussion

- Reduce the textarea height - previously it was 100vh, but this doesn't
  account for the height of the iOS keyboard, so I've just arbitrarily
  chosen 300px instead. There may be a better solution for this.
  ref #1269
2017-11-05 16:25:21 +10:30
Toby Zerner
3be98b9f8e Make sure dropdowns don't go above the edge of the screen 2017-11-05 16:17:50 +10:30
Toby Zerner
257ee936f4 Revert color to text input type
#1074 changed the input type for these fields to "color", but it turns
out the browser support for this input type sucks (they give you a very
limited color picker, and make it hard to input hex codes).
2017-11-05 16:17:15 +10:30
Toby Zerner
1a928ca0ab Fix admin navigation not rendering
Not sure why this started happening now, but the admin navigation
dropdown wasn't receiving its children properly. This commit fixes a
flaw in our Mithril patch and allows an array of children to be passed
in the normal JSX way, rather than as an attribute.
2017-11-05 16:12:26 +10:30
Franz Liedke
914b94b62d
Remove user bio feature (#1214)
The feature is very limited in scope, and we hope for community
extensions to take over this feature and make it much better.
2017-11-02 01:12:49 +01:00
Joseph
123c8bb73d Add drag and drop avatar uploading 2017-10-22 14:21:39 -07:00
Toby Zerner
f3b4d35587 Fix extractText breaking in some cases 2017-10-08 08:59:54 +10:30
Toby Zerner
42ecee42a1 Make sure components receive all children properly 2017-10-08 08:59:18 +10:30
Toby Zerner
6a10b4484f Recompile JS 2017-10-07 20:12:15 +10:30
Toby Zerner
06aa37d2fd Use display names in avatars 2017-10-07 20:10:50 +10:30
Toby Zerner
19d15d4302 Use display name as document title 2017-10-05 11:43:12 +10:30
Toby Zerner
eb72307a54 User display names (#1246)
* Introduce user display names

It is not uncommon for forums to be intergrated with sites where users
don't have a unique "handle" - they might just have their first name,
or a full name, which is not guaranteed to be unique.

This commit introduces the concept of "display names" for users. By
default display names are the same as usernames, but extensions may
override this and set them to something different. The important thing
is that all code should use `display_name` whenever intending to output
a human-readable name - `username` is reserved for cases where you want
to output a unique identifier (which may or may not be human-friendly).

The new "GetDisplayName" API is probably sub-optimal, but I didn't worry
too much because we can come up with something better in `next-back`.

ref #557

* Apply fixes from StyleCI

[ci skip] [skip ci]
2017-09-20 16:42:18 +09:30
zinsserzh
7df9594a04 Add isEmpty function to ItemList (#1218)
* Add isEmpty function to ItemList

* Fix coding style to be consistent.

* Recompiled app.js for both js/admin/ and js/forum/
2017-08-10 11:37:00 +09:30
Franz Liedke
c037658675
Don't hardcode admin URL
Fixes #1219.
2017-08-04 23:37:59 +02:00
Franz Liedke
a2e0daed70
Remove faulty default value
Fixes #1210.
2017-07-27 00:55:33 +02:00
Toby Zerner
57f828b3f7 Fix user online icon spacing 2017-07-22 16:10:08 +09:30
Toby Zerner
5faf0fcde5 And remove unused import 2017-07-22 12:31:23 +09:30
Toby Zerner
65c0b436c0 Fix missed instance of back button tooltip 2017-07-22 12:30:55 +09:30
Toby Zerner
8d76168bd4 Oops, forgot to correct test code 2017-07-22 12:29:03 +09:30
Toby Zerner
d16f4dbefa Recompile JS 2017-07-22 12:08:17 +09:30
Toby Zerner
e3e4786391 Simplify global back button
The behaviour is not overly intuitive, and the icon wasn't helping
(hamburger icon usually means "menu"). Now the back button always goes
back to the index, no matter where you are, and there's a tooltip that
says "Back to discussion list".
2017-07-22 12:08:09 +09:30
Toby Zerner
c1c7d4c73a Only display "show language selector" toggle if there is more than one language 2017-07-22 11:47:50 +09:30
Toby Zerner
8da8c9ac7d Clean up appearance of Rename Discussion modal
Also fix infinite loading if there's a validation error.
2017-07-22 11:47:04 +09:30
Toby Zerner
fb68aa88db Use default dropdown appearance for sort dropdown 2017-07-22 11:46:16 +09:30