Skip to content

Commit

Permalink
Merge pull request #111 from lanedirt/108-do-not-show-fastbuild-icon-…
Browse files Browse the repository at this point in the history
…for-buildings-that-do-not-satisfy-requirements

Hide fastbuild icon when unsatisfied requirements
  • Loading branch information
lanedirt authored Apr 28, 2024
2 parents c031732 + 8b53465 commit f4399e8
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 12 deletions.
5 changes: 3 additions & 2 deletions resources/views/ingame/ajax/object.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -175,11 +175,12 @@
<button class="maximum">[max. {{ $max_build_amount }}]</button>
</div>
@elseif ($object_type == 'building' || $object_type == 'station')
<button class="downgrade" data-technology="3" data-name="{{ $title }}">
<!-- TODO: implement downgrade feature -->
<!--<button class="downgrade" data-technology="3" data-name="{{ $title }}">
<div class="demolish_img tooltipRel ipiHintable" rel="demolition_costs_tooltip_oneTimeelement"
data-ipi-hint="ipiTechnologyTearDowndeuteriumSynthesizer"></div>
<span class="label">tear down</span>
</button>
</button>-->
@endif

<div class="build-it_wrap">
Expand Down
16 changes: 11 additions & 5 deletions resources/views/ingame/facilities/index.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,17 @@
>

<span class="icon sprite sprite_medium medium {{ $building->object->class_name }}">
<button
class="upgrade tooltip hideOthers js_hideTipOnMobile"
aria-label="Expand {!! $building->object->title !!} on level {!! ($building->current_level + 1) !!}" title="Expand {!! $building->object->title !!} on level {!! ($building->current_level + 1) !!}"
data-technology="{{ $building->object->id }}" data-is-spaceprovider="">
</button>
@if ($building->currently_building)
@elseif (!$building->requirements_met)
@elseif (!$building->enough_resources)
@elseif ($build_queue_max)
@else
<button
class="upgrade tooltip hideOthers js_hideTipOnMobile"
aria-label="Expand {!! $building->object->title !!} on level {!! ($building->current_level + 1) !!}" title="Expand {!! $building->object->title !!} on level {!! ($building->current_level + 1) !!}"
data-technology="{{ $building->object->id }}" data-is-spaceprovider="">
</button>
@endif
@if ($building->currently_building)
<div class="cooldownBackground"></div>
<time-counter><time class="countdown buildingCountdown" id="countdownbuildingDetails" data-segments="2">...</time></time-counter>
Expand Down
16 changes: 11 additions & 5 deletions resources/views/ingame/resources/index.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,11 +56,17 @@
title="{{ $building->object->title }}"
@endif
><span class="icon sprite @if (in_array($building->object->machine_name, ['metal_store','crystal_store','deuterium_store'])) sprite_small small @else sprite_medium medium @endif {{ $building->object->class_name }}">
<button
class="upgrade tooltip hideOthers js_hideTipOnMobile"
aria-label="Expand {!! $building->object->title !!} on level {!! ($building->current_level + 1) !!}" title="Expand {!! $building->object->title !!} on level {!! ($building->current_level + 1) !!}"
data-technology="{{ $building->object->id }}" data-is-spaceprovider="">
</button>
@if ($building->currently_building)
@elseif (!$building->requirements_met)
@elseif (!$building->enough_resources)
@elseif ($build_queue_max)
@else
<button
class="upgrade tooltip hideOthers js_hideTipOnMobile"
aria-label="Expand {!! $building->object->title !!} on level {!! ($building->current_level + 1) !!}" title="Expand {!! $building->object->title !!} on level {!! ($building->current_level + 1) !!}"
data-technology="{{ $building->object->id }}" data-is-spaceprovider="">
</button>
@endif
@if ($building->currently_building)
<div class="cooldownBackground"></div>
<time-counter><time class="countdown buildingCountdown" id="countdownbuildingDetails" data-segments="2">...</time></time-counter>
Expand Down

0 comments on commit f4399e8

Please sign in to comment.