@eturnity/eturnity_reusable_components 7.8.6-EPDM-7779.3 → 7.8.6-EPDM-7779.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@eturnity/eturnity_reusable_components",
3
- "version": "7.8.6-EPDM-7779.3",
3
+ "version": "7.8.6-EPDM-7779.4",
4
4
  "private": false,
5
5
  "scripts": {
6
6
  "dev": "vue-cli-service serve",
@@ -46,6 +46,7 @@
46
46
  @keydown.native="onKeyDown"
47
47
  :showBorder="showBorder"
48
48
  :data-id="dataId"
49
+ :paddingLeft="paddingLeft"
49
50
  >
50
51
  <draggableInputHandle v-if="isDraggable && !isSearchBarVisible" :height="selectHeight" />
51
52
  <inputText
@@ -64,7 +65,7 @@
64
65
  @input-change="searchChange"
65
66
  @click.native.stop
66
67
  />
67
- <selector :selectWidth="selectWidth" v-else>
68
+ <selector v-else :selectWidth="selectWidth" :paddingLeft="paddingLeft">
68
69
  <slot name="selector" :selectedValue="selectedValue"></slot>
69
70
  </selector>
70
71
  <Caret @click.stop="toggleCaretDropdown">
@@ -145,7 +146,6 @@ import inputText from '../inputText'
145
146
  import draggableInputHandle from '../../draggableInputHandle'
146
147
 
147
148
  const CARET_WIDTH = '30px'
148
- const PADDING = this.isDraggable ? '30px' : '15px'
149
149
  const BORDER_WIDTH = '1px'
150
150
 
151
151
  const Caret = styled.div`
@@ -160,8 +160,8 @@ const Caret = styled.div`
160
160
  margin-left: auto;
161
161
  `
162
162
 
163
- const Selector = styled('div', { selectWidth: String })`
164
- max-width: ${(props) => `calc(${props.selectWidth} - (${CARET_WIDTH} + ${PADDING} + (${BORDER_WIDTH} * 2)))`};
163
+ const Selector = styled('div', { selectWidth: String, paddingLeft: String })`
164
+ max-width: ${(props) => `calc(${props.selectWidth} - (${CARET_WIDTH} + ${props.paddingLeft} + (${BORDER_WIDTH} * 2)))`};
165
165
  white-space: nowrap;
166
166
  text-overflow: ellipsis;
167
167
  overflow: hidden;
@@ -209,13 +209,14 @@ const selectButtonAttrs = {
209
209
  height: String,
210
210
  selectMinHeight: String,
211
211
  isSearchBarVisible: Boolean,
212
- showBorder: Boolean
212
+ showBorder: Boolean,
213
+ paddingLeft: String
213
214
  }
214
215
  const selectButton = styled('div', selectButtonAttrs)`
215
216
  position: relative;
216
217
  box-sizing: border-box;
217
218
  border-radius: 4px;
218
- ${(props) => (props.isSearchBarVisible ? '' : `padding-left: ${PADDING}` )};
219
+ ${(props) => (props.isSearchBarVisible ? '' : `padding-left: ${props.paddingLeft}` )};
219
220
  text-align: left;
220
221
  min-height: ${(props) =>
221
222
  props.selectHeight
@@ -441,6 +442,7 @@ export default {
441
442
  data() {
442
443
  return {
443
444
  selectedValue: null,
445
+ paddingLeft: this.isDraggable ? '30px' : '15px',
444
446
  isDropdownOpen: false,
445
447
  isActive: false,
446
448
  textSearch: '',