Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(transfer): adjust filter inputs and container spacing [LIBS-728] #1650

Merged
merged 2 commits into from
Dec 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions components/transfer/src/filter.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ export const Filter = ({ dataTest, filter, onChange, label, placeholder }) => (
<div data-test={dataTest}>
<Field label={label} name={dataTest} dataTest={`${dataTest}-field`}>
<Input
dense
dataTest={`${dataTest}-input`}
type="search"
placeholder={placeholder}
Expand Down
2 changes: 0 additions & 2 deletions components/transfer/src/options-container.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import { spacers } from '@dhis2/ui-constants'
import { CircularLoader } from '@dhis2-ui/loader'
import PropTypes from 'prop-types'
import React, { Fragment, useRef } from 'react'
Expand Down Expand Up @@ -69,7 +68,6 @@ export const OptionsContainer = ({
<style jsx>{`
.optionsContainer {
flex-grow: 1;
padding: ${spacers.dp4} 0;
position: relative;
overflow: hidden;
}
Expand Down
10 changes: 9 additions & 1 deletion components/transfer/src/transfer-option.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { colors } from '@dhis2/ui-constants'
import { colors, spacers } from '@dhis2/ui-constants'
import cx from 'classnames'
import PropTypes from 'prop-types'
import React, { useRef } from 'react'
Expand Down Expand Up @@ -66,6 +66,14 @@ export const TransferOption = ({
color: ${colors.grey600};
cursor: not-allowed;
}

div:first-child {
margin-block-start: ${spacers.dp4};
}

div:last-child {
margin-block-end: ${spacers.dp4};
}
`}</style>
</div>
)
Expand Down
Loading