Commit Graph

5827 Commits

Author SHA1 Message Date
Jordan Vidrine 366f5e08d7
FIX: Copy & Fullscreen button edits in codeblocks (#20483) 2023-02-28 10:54:24 -06:00
Jarek Radosz c81d4f60af
UX: Fix large onebox avatars in img chat messages (#20469)
When you included an image and a full-line (github) onebox in a single message the user avatar in the inbox would be incorrectly embiggened.
2023-02-27 23:03:02 +01:00
Kris 90ed30b3ff
UX: fix tag & category clicks on mobile topic list (#20449) 2023-02-24 15:29:57 -05:00
Keegan George 6108eee31d
DEV: Apply form template to categories (#20337) 2023-02-23 11:18:14 -08:00
chapoi ab46a05d77
UX: User badges tweaks (#20408)
* UX: fix standalone badge padding

* UX: badge number formatting

* UX: copy

* DEV: Add LinkTo for the admin-badges/show count text

* UX: user badge awarded style update

---------

Co-authored-by: Martin Brennan <martin@discourse.org>
2023-02-23 03:21:26 +01:00
Martin Brennan a3712781e1
FIX: Text selection breaking with hashtag SVG in Firefox (#20406)
The new hashtags render with an `<svg>` element inside a `<a>`
tag, which is an icon to indicate the "type" of the hashtag.
In Firefox, this was disrupting both triple-click text selection
and simple dragging cursor text selection. The selection would
stop at the SVG rather than continuing past it. This works fine
in Chrome -- either Chrome is not doing the right thing or Firefox
is.

Either way the issue is fixed by simply making the `svg` an inline
element inside the link, which it should be anyway.
2023-02-22 13:56:08 +10:00
Krzysztof Kotlarek b9d037770c
DEV: configurable public sidebar sections (#20303)
Extension of https://github.com/discourse/discourse/pull/20057

Admin can create a public session visible to everyone. An additional checkbox is displayed for staff members.
2023-02-22 08:55:44 +11:00
David Taylor 235edfd07b
UX: Restore wider search dropdown width (#20391)
Followup to c82094cd9d
2023-02-21 15:40:22 +00:00
David Taylor c82094cd9d
PERF: Refactor slide-in menu sizing for improved performance (#20377)
Using Javascript to read and recalculate sizing is prone to causing 'forced reflows', which are very expensive, especially on slower devices. This PR refactors the slide-in menus so that all of the height calculation is done using CSS. This is made possible by the new dvh (dynamic view height) units and env(safe-area-inset-bottom), both of which are supported on all of our target browsers.

In tests on a moto g50, on a sidebar with 16 categories, 15 tags, and 2 chat channels, this improves the sidebar opening time by around 50ms (6%).
2023-02-21 13:55:38 +00:00
chapoi 87de3c2319
UX: highlight vars updates (#20346)
* UX: replace highlight vars in popup menu

* UX: replace highlight vars in autcomplete

* UX: replace highlight vars in menu-panel

* UX: update style guide

* UX: bulk replace highlight vars in various small appearances
2023-02-21 10:15:49 +01:00
chapoi b50a581c5d
UX: badge page styling update (#20373)
* UX: change layout badge card

* UX:  copy change

* UX: badge list styling

* UX: make active badge styling more clear

* Update translation

Co-authored-by: Gerhard Schlager <gerhard.schlager@discourse.org>

* Include x in translation

Co-authored-by: Gerhard Schlager <gerhard.schlager@discourse.org>

---------

Co-authored-by: Gerhard Schlager <gerhard.schlager@discourse.org>
2023-02-20 15:14:54 +01:00
Keegan George 9c29d688e7
FEATURE: Add word count and indicator when exceeded max (#19367)
**This PR creates a new core reusable component wraps a character counter around any input.**

The component accepts the arguments: `max` (the maximum character limit), `value` (the value of text to be monitored).

It can be used for example, like so:
```hbs
  <CharCounter @max="50" @value={{this.charCounterContent}}>
    <textarea
      placeholder={{i18n "styleguide.sections.char_counter.placeholder"}}
      {{on "input" (action (mut this.charCounterContent) value="target.value")}}
      class="styleguide--char-counter"></textarea>
  </CharCounter>
```

**This PR also:**
1. Applies this component to the chat plugins edit channel's *Edit Description** modal, thereby replacing the simple text area which provided no visual indication when text exceeded the max allowed characters.
2. Adds an example to the `/styleguide` route
2023-02-20 12:06:43 +01:00
chapoi dc7a2f0d1a
UX: remove fixed width from buttons (#20369) 2023-02-20 11:17:17 +01:00
Kris d67ed8468f
UX: move vertical admin plugin nav to horizontal overflow nav (#20319) 2023-02-17 10:21:30 -05:00
chapoi 1a653d2ce9
Revert "Revert "Select-kit > use new color vars" (#20042)" (#20345)
This reverts commit 5f90790110.
2023-02-17 07:29:26 +01:00
chapoi 8465f53a35
UX: userstatus limit handling in UI (#20343)
* UX: handle long userstatus in menupanel

* UX: remove margin on userstatus emoji

* UX: change emoji sise of user status in DM creator

* FIX: user status overflow on chat index
2023-02-17 06:54:56 +01:00
Joffrey JAFFEUX 7391f8e077
FIX: correctly account for ipad footer nav height (#20334)
This code also removes duplicated code in chat which doesn’t seem necessary anymore.
2023-02-16 16:49:17 +01:00
chapoi 99eceab6bc
UX: catch edge cases in tooltip (#20327) 2023-02-16 10:34:17 +01:00
Krzysztof Kotlarek 1a5f6aefc7
FIX: correct sidebar and chat height on DiscourseHub (#20323)
Before that change, footer of the sidebar was not visible.
Footer is very important, especially now, when add custom section button is located there.
Also, distance between chat input and keyboard were increased
2023-02-16 15:59:09 +11:00
Jordan Vidrine d40143371b
UX: Style edits (#19927) 2023-02-15 11:02:16 -06:00
Canapin 4bfa130c3a
UX: Fix remove-user-from-pm hover styling (#20273) 2023-02-15 11:06:21 -05:00
chapoi f19044af6a
UX: add transparent border for header icon (#20306) 2023-02-15 06:55:13 +01:00
Kris 2dbcea9eee
A11Y: Allow header logo/title to hide, if needed (#20244) 2023-02-14 09:04:48 -05:00
Kris 1c64b2dd95
UX: allow sidebar to appear inline down to 768px (#20271)
* UX: allow sidebar to appear inline down to 768px

* test fix

* fix typos
2023-02-14 09:51:42 +11:00
Kris 8bc9acc414
A11Y: Header icons should be buttons, not links (#20242) 2023-02-10 13:55:51 -05:00
chapoi 47abe61994
UX: add flex alignment for form actions (#20240) 2023-02-10 07:35:18 -06:00
Keegan George 6338287e89
UX: Easily toggle badges in admin badge list (#20225) 2023-02-09 11:36:27 -08:00
Penar Musaraj 58123e8089
Revert "UX: flex horizontal form controls (#20098)" (#20228)
This reverts commit 15b546978f.
2023-02-09 12:35:15 -05:00
Kris beee9623ec
UX: improve layout of keyboard shortcut modal (#20220) 2023-02-08 16:39:32 -05:00
Keegan George 871607a420
DEV: Create form templates (#20189) 2023-02-08 11:21:39 -08:00
Isaac Janzen 96c1fad2fe
UX: Fix `timeline-handle` positioning (#20217)
Positioning of the timeline handle was slightly off on the glimmer-topic-timeline

# Before
<img width="451" alt="Screenshot 2023-02-08 at 11 30 18 AM" src="https://user-images.githubusercontent.com/50783505/217606919-2f07b69f-4820-4b72-805b-ed28b34c79dc.png">


# After
<img width="447" alt="Screenshot 2023-02-08 at 11 29 53 AM" src="https://user-images.githubusercontent.com/50783505/217606811-977f52df-6070-4127-80c1-27c97174a9a7.png">
2023-02-08 12:01:14 -06:00
Krzysztof Kotlarek 6e1f3e0023
FIX: improvements for user custom sections (#20190)
Improvements for this PR: https://github.com/discourse/discourse/pull/20057

What was fixed:
- [x] Use ember transitions instead of full reload
- [x] Link was inaccurately kept active
- [x] "+ save" renamed to just "save"
- [x] Render emojis in link name
- [x] UI to set icon
- [x] Delete link is trash icon instead of "x"
- [x] Add another link to on the left and rewording
- [x] Raname "link name" -> "name", "points to" ->  link
- [x] Add limits to fields
- [x] Move add section button to the bottom
2023-02-08 11:45:34 +11:00
Kris 67ef46894f
UX: allow tags to wrap under categories on mobile (#20187) 2023-02-07 13:44:07 -05:00
Rafael dos Santos Silva 6e522e4aad
DEV: Move to Sass compilation to dart-sass (#19910)
This PR is a major change to Sass compilation in Discourse.

The new version of sass-ruby moves to dart-sass putting we back on the supported version of Sass. It does so while keeping compatibility with the existing method signatures, so minimal change is needed in Discourse for this change.

This moves us

From:
  - sassc 2.0.1 (Feb 2019)
  - libsass 3.5.2 (May 2018)

To:
  - dart-sass 1.58

This update applies the following breaking changes:

> 
> These breaking changes are coming soon or have recently been released:
> 
>  [Functions are stricter about which units they allow](https://sass-lang.com/documentation/breaking-changes/function-units) beginning in Dart Sass 1.32.0.
> 
>  [Selectors with invalid combinators are invalid](https://sass-lang.com/documentation/breaking-changes/bogus-combinators) beginning in Dart Sass 1.54.0.
> 
>  [/ is changing from a division operation to a list separator](https://sass-lang.com/documentation/breaking-changes/slash-div) beginning in Dart Sass 1.33.0.
> 
>  [Parsing the special syntax of @-moz-document will be invalid](https://sass-lang.com/documentation/breaking-changes/moz-document) beginning in Dart Sass 1.7.2.
> 
>  [Compound selectors could not be extended](https://sass-lang.com/documentation/breaking-changes/extend-compound) in Dart Sass 1.0.0 and Ruby Sass 4.0.0.


SCSS files have been migrated automatically using `sass-migrator division app/assets/stylesheets/**/*.scss`
2023-02-07 12:24:57 -03:00
Penar Musaraj d29dc087b2
FEATURE: Support collapsing array sections in JSON Schema field types (#20118)
This allows users to collapse array-type data tables in JSON Schema
fields. Note that this data type is currently only used in themes and
plugins.
2023-02-07 08:22:01 -05:00
Kris ec4ac1465e
UX: show full topic title for reply-where (#20109) 2023-02-06 13:51:14 -05:00
Krzysztof Kotlarek 84a87a703c
DEV: configurable custom sidebar sections (#20057)
Allows users to configure their own custom sidebar sections with links withing Discourse instance. Links can be passed as relative path, for example "/tags" or full URL.

Only path is saved in DB, so when Discourse domain is changed, links will be still valid.

Feature is hidden behind SiteSetting.enable_custom_sidebar_sections. This hidden setting determines the group which members have access to this new feature.
2023-02-03 14:44:40 +11:00
Osama Sayegh f94951147e
FIX: Replace R2 gem with rtlcss for generating RTL CSS (#19636)
We've had a couple of problems with the R2 gem where it generated a broken RTL CSS bundle that caused a badly broken layout when Discourse is used in an RTL language, see a3ce93b and 5926386. For this reason, we're replacing R2 with `rtlcss` that can handle modern CSS features better than R2 does.

`rltcss` is written in JS and available as an npm package. Calling the `rltcss` from rubyland is done via the `rtlcss_wrapper` gem which contains a distributable copy of the `rtlcss` package and loads/calls it with Mini Racer. See https://github.com/discourse/rtlcss_wrapper for more details.

Internal topic: t/76263.
2023-02-01 14:21:15 +03:00
chapoi 15b546978f
UX: flex horizontal form controls (#20098) 2023-01-31 12:38:44 +01:00
Joffrey JAFFEUX 73488f2f33
FIX: uses popper for cards 2023-01-30 21:12:30 +01:00
Natalie Tay fda834d01c
Revert "DEV: uses popperjs for positioning user and group card (#20063)" (#20072)
This reverts commit 335c3f4621.
2023-01-31 02:51:05 +08:00
Joffrey JAFFEUX 335c3f4621
DEV: uses popperjs for positioning user and group card (#20063)
Behavior should be very similar but the code is simplified and it should fix various bugs where the card was showing out of screen even if we had available space.
2023-01-30 14:15:10 +01:00
chapoi 18f7b47ecb
UX: improve emoji alignment for text (#19815)
* UX: improve emoji alignment for text

* UX: emoji exception for titles
2023-01-30 14:07:08 +01:00
chapoi d0780eacdc
FIX: preserves avatar size inside onebox (#20066)
* UX: Wrap chat one-box avatars

* UX: restrict onebox image css to non-avatar
2023-01-30 13:59:25 +01:00
Ayke Halder 137dbaf0dc
DEV: declare post position as simple number in structured data (#16231)
This replaces the position declared as `#123` with the more simple version `123`.

The property position may be of type Integer or Text. A value of type Integer, or more precise of type Text which simply casts to integer, is sufficient here.
See: https://schema.org/position

In category-view the topic-list already uses this notation for the position of topics:
`<meta itemprop="position" content="123">`
2023-01-30 08:07:04 +01:00
Keegan George a4c68d4a2e
FIX: Failing system spec for rate limited search (#20046) 2023-01-27 12:14:29 -08:00
chapoi 5f90790110
Revert "Select-kit > use new color vars" (#20042)
This reverts commit 8534391044.
2023-01-27 18:09:50 +01:00
chapoi e03f6057ec
UX: Highlight var refactor (#20026)
* Add new color vars

* Select-kit > use new color vars

* update all color schemes with values for new hover/select vars

* Add variable yml names
2023-01-27 15:50:36 +01:00
Kris e71bf672cb
UX: prevent user card status overflow (#19979) 2023-01-24 13:58:24 -05:00
Kris 7683b4bbfa
UX: improve bulk button layout and alignment (#19966) 2023-01-24 09:47:35 -05:00