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

Advanced search UI #66

Merged
merged 5 commits into from
Feb 19, 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
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@eeacms/volto-widget-geolocation",
"version": "5.1.7",
"version": "5.2.0",
"description": "volto-widget-geolocation: Volto add-on",
"main": "src/index.js",
"author": "European Environment Agency: IDM2 A-Team",
Expand Down
51 changes: 27 additions & 24 deletions src/components/manage/Widgets/GeolocationWidget.jsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React, { useState } from 'react';
import PropTypes from 'prop-types';
import { Grid, Button, Segment } from 'semantic-ui-react';
import { Grid, Button } from 'semantic-ui-react';
import { defineMessages, injectIntl } from 'react-intl';
import { useSelector, useDispatch } from 'react-redux';
import { FormFieldWrapper, Icon, SidebarPopup } from '@plone/volto/components';
Expand Down Expand Up @@ -199,29 +199,32 @@ const GeolocationWidget = (props) => {
/>
</Grid.Column>
</Grid.Row>
<Grid.Row stretched>
<Segment attached className="actions">
<Button
size="mini"
basic
primary
floated="left"
onClick={(event) => {
setPopup(true);
event.preventDefault();
}}
>
<Icon
name={zoomSVG}
size="30px"
className="addSVG"
title={intl.formatMessage(messages.search)}
/>
</Button>
<label className={'popup-label'}>
{intl.formatMessage(messages.search)}
</label>
</Segment>
<Grid.Row stretched style={{ padding: '10px 0' }}>
<Grid.Column width="4">
<div className="wrapper">
<label htmlFor="advanced-search-button ">
{intl.formatMessage(messages.search)}
</label>
</div>
</Grid.Column>
<Grid.Column width="8" className="search-grid-column">
<div class="add-item-button-wrapper">
<Button
className="icon advanced-search-button"
onClick={(event) => {
setPopup(true);
event.preventDefault();
}}
>
<Icon
name={zoomSVG}
size="16px"
title={intl.formatMessage(messages.search)}
/>
Search
</Button>
</div>
</Grid.Column>
<SidebarPopup open={isOpenPopup}>
<SearchGeoName
id={id}
Expand Down
2 changes: 1 addition & 1 deletion src/components/manage/Widgets/ListResults.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ const ListResults = ({
<a
href={`https://www.geonames.org/${item.geonameId}`}
target="_blank"
rel="noreferrer"
rel="noreferrer noopener"
>
{item.geonameId}
</a>
Expand Down
6 changes: 0 additions & 6 deletions src/components/manage/Widgets/public.less
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,6 @@
vertical-align: sub;
}

.ui.attached.segment.actions {
display: flex;
align-items: center;
gap: 1rem;
}

// Temporary style fix
.geo-field-wrapper {
> .ui.grid .row .twelve.column {
Expand Down