Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(nlu): intent slot formatting #295

Merged
merged 1 commit into from
Feb 21, 2022

Conversation

rob-gordon
Copy link
Contributor

Before

Screen.Recording.2022-02-15.at.3.45.28.PM.mov

After

Screen.Recording.2022-02-15.at.3.42.52.PM.mov

@linear
Copy link

linear bot commented Feb 15, 2022

DEV-2312 Intent Slot Formatting Bug

Styles for intent slots format incorrectly on smaller screen sizes

Screen Shot 2022-02-09 at 9.59.29 AM.png

Comment on lines +80 to +90
// Fix duplicate placeholder
[data-slate-leaf='true'] > span > [contenteditable='false'] + span > [contenteditable='false'],
[data-slate-leaf='true']
> span
> [contenteditable='false']
+ span
> [contenteditable='false']
+ span
> [contenteditable='false'] {
display: none !important;
}
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I totally acknowledge how hacky this looks! It fixes a bug (which already existed) where the placeholder is rendered 3 times on the first line for some reason. I tried to fix it via the react-slate-placeholder plugin, but it's undocumented and unmaintained and I didn't have any luck :^\
Screen Shot 2022-02-15 at 3 53 51 PM

Copy link
Member

@franklevasseur franklevasseur left a comment

Choose a reason for hiding this comment

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

I tried it and it works perfect 👍

@@ -6,7 +6,7 @@ $status-bar-height: 30px;
}

.fullsize,
.fullsize > div {
.fullsize > :where(div) {
Copy link
Member

Choose a reason for hiding this comment

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

what is this sorcery ?? 🧙🏻‍♂️

Copy link
Contributor

Choose a reason for hiding this comment

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

Copy link
Contributor

@laurentlp laurentlp left a comment

Choose a reason for hiding this comment

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

Tested and LGTM

@rob-gordon rob-gordon merged commit 2d1b01b into master Feb 21, 2022
@rob-gordon rob-gordon deleted the robgordon-dev-2312-intent-slot-formatting-bug branch February 21, 2022 13:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants