Skip to content

Commit

Permalink
add break-word wrap to add/edit text box on dashboard
Browse files Browse the repository at this point in the history
  • Loading branch information
alison985 committed Jun 10, 2018
1 parent c86423a commit d116381
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion client/app/components/dashboards/add-widget-dialog.html
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ <h4 class="modal-title">Add Widget</h4>
</div>
<div ng-show="$ctrl.text" class="m-t-15">
<strong>Preview:</strong>
<p ng-bind-html="$ctrl.text | markdown"></p>
<p ng-bind-html="$ctrl.text | markdown" class="word-wrap-break"></p>
</div>
</div>

Expand Down
1 change: 1 addition & 0 deletions client/app/components/dashboards/add-widget-dialog.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { debounce } from 'underscore';
import template from './add-widget-dialog.html';
import './add-widget-dialog.less';

const AddWidgetDialog = {
template,
Expand Down
3 changes: 3 additions & 0 deletions client/app/components/dashboards/add-widget-dialog.less
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.word-wrap-break {
word-wrap: break-word;
}
2 changes: 1 addition & 1 deletion client/app/components/dashboards/edit-text-box.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ <h4 class="modal-title">Edit TextBox</h4>
</div>
<div ng-show="$ctrl.widget.new_text">
<strong>Preview:</strong>
<p ng-bind-html="$ctrl.widget.new_text | markdown"></p>
<p ng-bind-html="$ctrl.widget.new_text | markdown" class="word-wrap-break"></p>
</div>
</div>

Expand Down
1 change: 1 addition & 0 deletions client/app/components/dashboards/widget.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import template from './widget.html';
import editTextBoxTemplate from './edit-text-box.html';
import './widget.less';
import './add-widget-dialog.less';

const EditTextBoxComponent = {
template: editTextBoxTemplate,
Expand Down

0 comments on commit d116381

Please sign in to comment.