- that.$el
- .position({
- my: edge + ' bottom',
- // Move the toolbar 1px towards the start edge of the 'of' element,
- // plus any horizontal padding that may have been added to the
- // element that is being added, to prevent unwanted horizontal
- // movement.
- at: edge + '+' + (1 + horizontalPadding) + ' top',
- of: of,
- collision: 'flipfit',
- using: refinePosition.bind(null, that),
- within: that.$fence
- })
- // Resize the toolbar to match the dimensions of the field, up to a
- // maximum width that is equal to 90% of the field's width.
- .css({
- 'max-width': (document.documentElement.clientWidth < 450) ? document.documentElement.clientWidth : 450,
- // Set a minimum width of 240px for the entity toolbar, or the width
- // of the client if it is less than 240px, so that the toolbar
- // never folds up into a squashed and jumbled mess.
- 'min-width': (document.documentElement.clientWidth < 240) ? document.documentElement.clientWidth : 240,
- 'width': '100%'
- });
+ that.$el.position({
+ my: edge + ' bottom',
+
+ at: edge + '+' + (1 + horizontalPadding) + ' top',
+ of: of,
+ collision: 'flipfit',
+ using: refinePosition.bind(null, that),
+ within: that.$fence
+ }).css({
+ 'max-width': document.documentElement.clientWidth < 450 ? document.documentElement.clientWidth : 450,
+
+ 'min-width': document.documentElement.clientWidth < 240 ? document.documentElement.clientWidth : 240,
+ width: '100%'
+ });