Skip to content
This repository has been archived by the owner on Mar 4, 2020. It is now read-only.

fix(Chat): use more accurate positioning in scrollable containers #1929

Merged
merged 5 commits into from
Sep 13, 2019

Conversation

layershifter
Copy link
Member

@layershifter layershifter commented Sep 13, 2019

Fixes #1926.


Previously we used unstable_pinned on actions, this prop will only disable flip modifier which is not correct.

This PR does these changes:

  • flip modifier is enabled and will move actions only on top
  • preventOverflow will work only for left/right positions

Before

image

After

image

@codecov
Copy link

codecov bot commented Sep 13, 2019

Codecov Report

Merging #1929 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #1929   +/-   ##
=======================================
  Coverage   70.47%   70.47%           
=======================================
  Files         884      884           
  Lines        7796     7796           
  Branches     2280     2256   -24     
=======================================
  Hits         5494     5494           
  Misses       2291     2291           
  Partials       11       11
Impacted Files Coverage Δ
packages/react/src/components/Chat/ChatMessage.tsx 75.51% <ø> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 06d3814...bfbccf6. Read the comment docs.

@vercel vercel bot temporarily deployed to staging September 13, 2019 10:13 Inactive
@vercel vercel bot temporarily deployed to staging September 13, 2019 10:17 Inactive

const useRangeKnob = (options: UseRangeKnobOptions) => {
const { initialValue = 3, min = 0, max = parseValue(initialValue), step = 1, ...rest } = options
const useRangeKnob = <T extends number | string>(options: UseRangeKnobOptions<T>) => {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix to properly define number/string return type

@jurokapsiar jurokapsiar merged commit 98b8229 into master Sep 13, 2019
@jurokapsiar jurokapsiar deleted the fix/chat-message branch September 13, 2019 11:48
layershifter added a commit that referenced this pull request Sep 13, 2019
)

* fix(Chat): use more accurate positioning in scrollable containers

* add example

* add changelog

(cherry picked from commit 98b8229)
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Chat: Message action clipped on the left side if message is short
2 participants