Improve place-create button
This commit is contained in:
@@ -15,6 +15,7 @@ import mapPin from 'feather-icons/dist/icons/map-pin.svg?raw';
|
|||||||
import menu from 'feather-icons/dist/icons/menu.svg?raw';
|
import menu from 'feather-icons/dist/icons/menu.svg?raw';
|
||||||
import navigation from 'feather-icons/dist/icons/navigation.svg?raw';
|
import navigation from 'feather-icons/dist/icons/navigation.svg?raw';
|
||||||
import phone from 'feather-icons/dist/icons/phone.svg?raw';
|
import phone from 'feather-icons/dist/icons/phone.svg?raw';
|
||||||
|
import plus from 'feather-icons/dist/icons/plus.svg?raw';
|
||||||
import server from 'feather-icons/dist/icons/server.svg?raw';
|
import server from 'feather-icons/dist/icons/server.svg?raw';
|
||||||
import settings from 'feather-icons/dist/icons/settings.svg?raw';
|
import settings from 'feather-icons/dist/icons/settings.svg?raw';
|
||||||
import target from 'feather-icons/dist/icons/target.svg?raw';
|
import target from 'feather-icons/dist/icons/target.svg?raw';
|
||||||
@@ -37,6 +38,7 @@ const ICONS = {
|
|||||||
menu,
|
menu,
|
||||||
navigation,
|
navigation,
|
||||||
phone,
|
phone,
|
||||||
|
plus,
|
||||||
server,
|
server,
|
||||||
settings,
|
settings,
|
||||||
target,
|
target,
|
||||||
|
|||||||
@@ -202,10 +202,10 @@ export default class PlacesSidebar extends Component {
|
|||||||
|
|
||||||
<button
|
<button
|
||||||
type="button"
|
type="button"
|
||||||
class="create-place-btn"
|
class="btn btn-outline create-place"
|
||||||
{{on "click" this.createNewPlace}}
|
{{on "click" this.createNewPlace}}
|
||||||
>
|
>
|
||||||
<Icon @name="plus" @size={{18}} />
|
<Icon @name="plus" @size={{18}} @color="#007bff" />
|
||||||
Create new place
|
Create new place
|
||||||
</button>
|
</button>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
|||||||
@@ -244,7 +244,9 @@ export default class StorageService extends Service {
|
|||||||
|
|
||||||
// Update both lists
|
// Update both lists
|
||||||
this.savedPlaces = this.savedPlaces.filter((p) => p.id !== place.id);
|
this.savedPlaces = this.savedPlaces.filter((p) => p.id !== place.id);
|
||||||
this.placesInView = this.placesInView.filter((p) => p.id !== place.id);
|
if (this.placesInView.length > 0) {
|
||||||
|
this.placesInView = this.placesInView.filter((p) => p.id !== place.id);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@action
|
@action
|
||||||
|
|||||||
@@ -688,41 +688,22 @@ span.icon {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Helper Text */
|
|
||||||
.helper-text {
|
.helper-text {
|
||||||
background: #eef4fc;
|
background: #eef4fc;
|
||||||
color: #1a5c9b;
|
color: #1a5c9b;
|
||||||
padding: 0.75rem;
|
padding: 0.75rem;
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
font-size: 0.9rem;
|
font-size: 0.9rem;
|
||||||
|
margin-top: 0;
|
||||||
margin-bottom: 1rem;
|
margin-bottom: 1rem;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 0.5rem;
|
gap: 0.5rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Create Place Button */
|
button.create-place {
|
||||||
.create-place-btn {
|
|
||||||
width: 100%;
|
width: 100%;
|
||||||
padding: 1rem;
|
margin: 1.5rem auto;
|
||||||
margin-top: 1rem;
|
|
||||||
background: white;
|
|
||||||
border: 1px dashed #ccc;
|
|
||||||
border-radius: 8px;
|
|
||||||
color: #666;
|
|
||||||
font-weight: 500;
|
|
||||||
cursor: pointer;
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
justify-content: center;
|
|
||||||
gap: 0.5rem;
|
|
||||||
transition: all 0.2s;
|
|
||||||
}
|
|
||||||
|
|
||||||
.create-place-btn:hover {
|
|
||||||
background: #f8f9fa;
|
|
||||||
border-color: #999;
|
|
||||||
color: #333;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@media (width <= 768px) {
|
@media (width <= 768px) {
|
||||||
|
|||||||
Reference in New Issue
Block a user