imbric-theme 0.7.4 → 0.7.5

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.
@@ -7,7 +7,7 @@ import withStyles from '../../hocs/withStyles'
7
7
  import DynamicSelect from '../../molecules/DynamicSelect'
8
8
 
9
9
 
10
- export const FooterTable = ({ getStyles, range, setPage, setDataPage, page, slice, placeholderDinamicSelect, handleResultsForPage }) => {
10
+ export const FooterTable = ({ getStyles, range, setPage, setDataPage, page, slice, placeholderDinamicSelect, handleResultsForPage, defaultValueSelect }) => {
11
11
  useEffect(() => {
12
12
  if (slice.length < 1 && page !== 1) {
13
13
  setPage(page - 1);
@@ -22,32 +22,32 @@ export const FooterTable = ({ getStyles, range, setPage, setDataPage, page, slic
22
22
  {range.map((el, index) => (
23
23
 
24
24
 
25
- <button
26
- key={'footer' + index}
27
- className={`${styles.button} ${page === el ? styles.activeButton : styles.inactiveButton
28
- }`}
29
- onClick={() => { setPage(el); setDataPage(el) }}
25
+ <button
26
+ key={'footer' + index}
27
+ className={`${styles.button} ${page === el ? styles.activeButton : styles.inactiveButton
28
+ }`}
29
+ onClick={() => { setPage(el); setDataPage(el) }}
30
30
 
31
- onChange={item => { handleSelectRange(item); onChangeRange(item); }}
31
+ onChange={item => { handleSelectRange(item); onChangeRange(item); }}
32
+
33
+ >
34
+ {el}
35
+ </button>
32
36
 
33
- >
34
- {el}
35
- </button>
36
37
 
37
38
 
38
-
39
39
 
40
40
  ))}
41
41
  </div>
42
42
 
43
43
  <DynamicSelect
44
- isInline
45
- onChange={handleResultsForPage}
46
- optionsSelect={options.opResultsForPage}
47
- placeholder={placeholderDinamicSelect}
48
- isClearable={false}
49
- defaultValue= { {value: 10, label: '10'} }
50
- />
44
+ isInline
45
+ onChange={handleResultsForPage}
46
+ optionsSelect={options.opResultsForPage}
47
+ placeholder={placeholderDinamicSelect}
48
+ isClearable={false}
49
+ defaultValue={defaultValueSelect}
50
+ />
51
51
 
52
52
  </div>
53
53
 
@@ -60,7 +60,8 @@ FooterTable.propTypes = {
60
60
  getStyles: PropTypes.func.isRequired,
61
61
  setDataPage: PropTypes.func,
62
62
  placeholderDinamicSelect: PropTypes.string,
63
- handleResultsForPage: PropTypes.func
63
+ handleResultsForPage: PropTypes.func,
64
+ defaultValueSelect: PropTypes.any
64
65
  // type: PropTypes.oneOf(options.types),
65
66
  }
66
67
 
@@ -68,7 +69,8 @@ FooterTable.defaultProps = {
68
69
  getStyles: () => { },
69
70
  setDataPage: () => { },
70
71
  handleResultsForPage: () => { },
71
- placeholderDinamicSelect: 'resultados por pagina'
72
+ placeholderDinamicSelect: 'resultados por pagina',
73
+ defaultValueSelect: { value: 10, label: '10' }
72
74
  }
73
75
 
74
76
  export default withStyles(styles)(FooterTable)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "imbric-theme",
3
- "version": "0.7.4",
3
+ "version": "0.7.5",
4
4
  "description": "Components library IMBRIC",
5
5
  "private": false,
6
6
  "main": "index.js",