Skip to content

Commit

Permalink
review
Browse files Browse the repository at this point in the history
  • Loading branch information
olegstan committed Jul 27, 2023
1 parent 6c3749b commit 81fffa4
Show file tree
Hide file tree
Showing 13 changed files with 78 additions and 77 deletions.
10 changes: 5 additions & 5 deletions src/components/Form/AccountGroupSelect/slimstyles.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import styled from 'styled-components'
import {
sharedItemStyle,
sharedSelectedStyle,
sharedSelectStyle,
sharedSelectWrapperStyle,
sharedSubItemStyle
sharedItemStyle,
sharedSelectedStyle,
sharedSelectStyle,
sharedSelectWrapperStyle,
sharedSubItemStyle
} from '../newslimstyles'

export const InputWrapper = styled.div`
Expand Down
14 changes: 7 additions & 7 deletions src/components/Form/GroupSearch/GroupRemoteSearch.jsx
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import React from 'react';
import BaseInput from '../BaseInput';
import {
Container,
Input as StyledInput,
InputContainer,
InputWrapper,
Item,
Select as StyledSelect,
SubItem
Container,
Input as StyledInput,
InputContainer,
InputWrapper,
Item,
Select as StyledSelect,
SubItem
} from './newstyles'
import {Loader} from '../newstyles'
import InputPopup from "../InputPopup/InputPopup";
Expand Down
14 changes: 7 additions & 7 deletions src/components/Form/GroupSearch/newstyles.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import styled from 'styled-components'
import {
sharedInputStyle,
sharedItemStyle,
sharedSearchContainer,
sharedSearchContainerStyle,
sharedSearchInputWrapperStyle,
sharedSelectedStyle,
sharedSelectStyle
sharedInputStyle,
sharedItemStyle,
sharedSearchContainer,
sharedSearchContainerStyle,
sharedSearchInputWrapperStyle,
sharedSelectedStyle,
sharedSelectStyle
} from '../newstyles'

export const Container = styled.div`
Expand Down
10 changes: 5 additions & 5 deletions src/components/Form/GroupSelect/styles.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import styled from 'styled-components'
import {
sharedItemStyle,
sharedSelectedStyle,
sharedSelectStyle,
sharedSelectWrapperStyle,
sharedSubItemStyle
sharedItemStyle,
sharedSelectedStyle,
sharedSelectStyle,
sharedSelectWrapperStyle,
sharedSubItemStyle
} from '../newstyles'

export const InputWrapper = styled.div`
Expand Down
14 changes: 7 additions & 7 deletions src/components/Form/InputWithCurrency/InputWithCurrency.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@ import React from 'react';
import {connect} from "react-redux";
import BaseInput from '../BaseInput';
import {
Container,
Input as StyledInput,
InputContainer,
InputWrapper,
Item,
Select as StyledSelect,
Selected,
Container,
Input as StyledInput,
InputContainer,
InputWrapper,
Item,
Select as StyledSelect,
Selected,
} from './newcurrencystyles'
import Money from "../../Helpers/Money";

Expand Down
12 changes: 6 additions & 6 deletions src/components/Form/InputWithCurrency/newcurrencystyles.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import styled from 'styled-components'
import {
errorStyle,
placeholderStyle,
sharedInputStyle,
sharedItemStyle,
sharedSelectedStyle,
sharedSelectStyle
errorStyle,
placeholderStyle,
sharedInputStyle,
sharedItemStyle,
sharedSelectedStyle,
sharedSelectStyle
} from '../newstyles'

export const Input = styled.input`
Expand Down
4 changes: 2 additions & 2 deletions src/components/Form/Search/Search.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@ class Search extends BaseInput

render()
{
const { items, handle, selected, name, styleSelect } = this.props;
const { items, handle, selected, name, styleSelect, styleClearImage } = this.props;
const { focused } = this.state;

let search = this.state.search ? this.state.search.toLowerCase() : '';
Expand Down Expand Up @@ -394,7 +394,7 @@ class Search extends BaseInput
}}>
{resItems.length ? resItems : (selected ? '' : <Item className={this.props.className}><span>{typeof this.state.search === 'string' && this.state.search.length > 0 ? 'Ничего не найдено' : 'Ввидете запрос'}</span></Item>)}
</StyledSelect>
{!empty && this.props.showClearIcon && !this.props.disabled && <img className='close' src={require('./../../assets/ic_close_only.svg').default} onClick={(e) => {
{!empty && this.props.showClearIcon && !this.props.disabled && <img style={styleClearImage} className='close' src={require('./../../assets/ic_close_only.svg').default} onClick={(e) => {
this.setState({
search: '',
hasError: false
Expand Down
14 changes: 7 additions & 7 deletions src/components/Form/Search/newstyles.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import React from 'react';
import styled, {css} from 'styled-components'
import {
sharedInputStyle,
sharedItemStyle,
sharedSearchContainer,
sharedSearchContainerStyle,
sharedSearchInputWrapperStyle,
sharedSelectedStyle,
sharedSelectStyle
sharedInputStyle,
sharedItemStyle,
sharedSearchContainer,
sharedSearchContainerStyle,
sharedSearchInputWrapperStyle,
sharedSelectedStyle,
sharedSelectStyle
} from '../newstyles'

export const sharedContainer = css`
Expand Down
14 changes: 7 additions & 7 deletions src/components/Form/SearchMultiple/newstyles.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import styled from 'styled-components'
import {
errorStyle,
placeholderStyle,
sharedInputStyle,
sharedItemStyle,
sharedSearchContainer,
sharedSelectedStyle,
sharedSelectStyle
errorStyle,
placeholderStyle,
sharedInputStyle,
sharedItemStyle,
sharedSearchContainer,
sharedSelectedStyle,
sharedSelectStyle
} from '../newstyles'

let close = require('./images/close.svg').default;
Expand Down
14 changes: 7 additions & 7 deletions src/components/Form/SearchWithButton/styles.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import styled from 'styled-components'
import {
errorStyle,
placeholderStyle,
sharedInputStyle,
sharedItemStyle,
sharedSearchContainer,
sharedSelectedStyle,
sharedSelectStyle
errorStyle,
placeholderStyle,
sharedInputStyle,
sharedItemStyle,
sharedSearchContainer,
sharedSelectedStyle,
sharedSelectStyle
} from '../newstyles'

export const Container = styled.div`
Expand Down
18 changes: 9 additions & 9 deletions src/components/Form/SelectWithDays/SelectWithDays.jsx
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
import React, {Fragment} from 'react';
import BaseInput from '../BaseInput';
import {
CalendarContainer,
Container,
Day,
DaysContainer,
DaysTitle,
InputWrapper,
Item,
Select as StyledSelect,
Selected
CalendarContainer,
Container,
Day,
DaysContainer,
DaysTitle,
InputWrapper,
Item,
Select as StyledSelect,
Selected
} from './styles'

class SelectWithDays extends BaseInput
Expand Down
5 changes: 3 additions & 2 deletions src/components/Form/functions/formSearch.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export default function formSearch(Base)
{
class FormSearch extends Base
{
renderSearch({field, items, text, defaultText, disabled = false, onSearch = () => {}, callback, id, onClick, styleSelect = {}, styleInput = {}, styleWrapper = {}, styleContainer = {}, showClearIcon = false, className} = {})
renderSearch({field, items, text, defaultText, disabled = false, onSearch = () => {}, callback, id, onClick, styleSelect = {}, styleInput = {}, styleWrapper = {}, styleContainer = {}, styleClearImage = {}, showClearIcon = false, className} = {})
{
return <Search
default={defaultText}
Expand All @@ -22,6 +22,7 @@ export default function formSearch(Base)
styleInput={styleInput}
styleSelect={styleSelect}
styleContainer={styleContainer}
styleClearImage={styleClearImage}
styleWrapper={styleWrapper}
showClearIcon={showClearIcon}
onClick={onClick}
Expand Down Expand Up @@ -50,7 +51,7 @@ export default function formSearch(Base)
/>
}

renderSearchStyle1({field, items, text, defaultText, disabled = false, onSearch = () => {}, callback, id, onClick, styleSelect = {}, styleInput = {}, styleWrapper = {}, styleContainer = {}, showClearIcon = false, className} = {})
renderSearchStyle1({field, items, text, defaultText, disabled = false, onSearch = () => {}, callback, id, onClick, styleSelect = {}, styleInput = {}, styleWrapper = {}, styleContainer = {}, styleClearImage = {}, showClearIcon = false, className} = {})
{
return this.renderSearch({...arguments[0], ...{className: 'style1'}})
}
Expand Down
12 changes: 6 additions & 6 deletions src/components/Form/newcurrencystyles.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import styled from 'styled-components'
import {
errorStyle,
placeholderStyle,
sharedInputStyle,
sharedItemStyle,
sharedSelectedStyle,
sharedSelectStyle
errorStyle,
placeholderStyle,
sharedInputStyle,
sharedItemStyle,
sharedSelectedStyle,
sharedSelectStyle
} from './newstyles'

export const Input = styled.input`
Expand Down

0 comments on commit 81fffa4

Please sign in to comment.