Skip to content

Commit

Permalink
HtmlEditor: Update image uploading dropzone UI in Fluent
Browse files Browse the repository at this point in the history
  • Loading branch information
marker-dao authored Oct 16, 2023
1 parent 28cd3f6 commit ebbb3c5
Show file tree
Hide file tree
Showing 7 changed files with 19 additions and 3 deletions.
1 change: 1 addition & 0 deletions packages/devextreme/scss/widgets/fluent/_colors.scss
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ $base-border-color-accessible-hover: null !default;
$base-border-color-accessible-focused: null !default;
$base-neutral-border-color2: null !default;
$base-neutral-border-color3: null !default;
$base-neutral-border-color4: rgba(209, 209, 209, 1) !default; // #d1d1d1

$base-inverted-bg: null !default;
$base-element-bg: null !default;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,5 @@ $htmleditor-resize-frame-border-color: $base-accent !default;
$htmleditor-resize-handle-bg: $base-accent !default;
$htmleditor-mention-bg: $base-bg-selected !default;
$htmleditor-table-border-color: $base-border-color !default;
$htmleditor-fileuploader-input-wrapper-border-color: $base-neutral-border-color4 !default;
$htmleditor-fileuploader-input-wrapper-bg-color: $base-neutral-background2 !default;
14 changes: 13 additions & 1 deletion packages/devextreme/scss/widgets/fluent/htmlEditor/_index.scss
Original file line number Diff line number Diff line change
Expand Up @@ -239,10 +239,22 @@
}

.dx-fileuploader-input-wrapper {
display: flex;
flex-direction: column;
align-items: center;
gap: 8px;
padding: $fluent-html-editor-add-image-dialog-fileuploader-padding;
border: 3px dashed $base-border-color;
border: 1px dashed $htmleditor-fileuploader-input-wrapper-border-color;
background-color: $htmleditor-fileuploader-input-wrapper-bg-color;
border-radius: $fluent-html-editor-fileuploader-input-wrapper-border-radius;

&::after,
&::before {
content: none;
}

.dx-fileuploader-input-label {
text-align: center;
border-width: 0;
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,19 +8,20 @@ $fluent-html-editor-vertical-padding: null !default;
$fluent-html-editor-horizontal-padding: null !default;
$fluent-html-editor-add-image-dialog-fileuploader-padding: null !default;
$fluent-html-editor-toolbar-menu-separator-margin: 4px !default;
$fluent-html-editor-fileuploader-input-wrapper-border-radius: 8px !default;

@if $size == "default" {
$fluent-toolbar-size-editor-width: 120px !default;
$fluent-html-editor-vertical-padding: 16px !default;
$fluent-html-editor-horizontal-padding: 16px !default;
$fluent-html-editor-add-image-dialog-fileuploader-padding: 50px 40px;
$fluent-html-editor-add-image-dialog-fileuploader-padding: 48px 0 24px;
}

@else if $size == "compact" {
$fluent-toolbar-size-editor-width: 90px !default;
$fluent-html-editor-vertical-padding: 12px !default;
$fluent-html-editor-horizontal-padding: 12px !default;
$fluent-html-editor-add-image-dialog-fileuploader-padding: 40px 30px;
$fluent-html-editor-add-image-dialog-fileuploader-padding: 40px 0 18px;
}

$fluent-htmleditor-toolbar-padding: $fluent-html-editor-horizontal-padding !default;
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit ebbb3c5

Please sign in to comment.