-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Minerals: switched structure from spots to tags
- Loading branch information
1 parent
7b47f96
commit 525f83b
Showing
18 changed files
with
455 additions
and
78 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<ion-modal-view> | ||
<ion-header-bar class='bar-stable nav-title-slide-ios7' align-title='center'> | ||
<button class='button button-positive' ng-click='vmChild.addMineralTagModal.hide();'>Done | ||
</button> | ||
<h1 class='title'>Add Mineral Tags</h1> | ||
<button class='button button-icon' ng-click='vmChild.addMineralTagModal.hide(); vm.createTag()'> | ||
<span class='icon ion-plus'></span> | ||
</button> | ||
</ion-header-bar> | ||
<ion-content class='has-header'> | ||
<ion-checkbox class='item-text-wrap item-button-right' | ||
ng-repeat='tag in vm.allMineralTags | orderBy:"name" track by tag.id' | ||
ng-checked='vm.isTagChecked(tag)' | ||
ng-click='vm.toggleTagChecked(tag)'> | ||
<b>{{ tag.name }}</b> | ||
<strabo-tags-list-properties-directive></strabo-tags-list-properties-directive> | ||
</ion-checkbox> | ||
</ion-content> | ||
</ion-modal-view> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
<div> | ||
<button ng-click='vm.addMineral("metamorphic_most_common")' class='button button-clear button-positive'> | ||
<i class='icon ion-plus-circled'></i> | ||
<span class='button-text-big'>Add/Remove Metamorphic Minerals</span> | ||
</button><br> | ||
<button ng-click='vm.addMineral("igneous_most_common")' class='button button-clear button-positive'> | ||
<i class='icon ion-plus-circled'></i> | ||
<span class='button-text-big'>Add/Remove Igneous Minerals</span> | ||
</button><br> | ||
<button ng-click='vm.addMineral("sedimentary_most_common")' class='button button-clear button-positive'> | ||
<i class='icon ion-plus-circled'></i> | ||
<span class='button-text-big'>Add/Remove Sedimentary Minerals</span> | ||
</button> | ||
<ion-list> | ||
<ion-item class='item-text-wrap item-button-right' | ||
ng-repeat='mineral in vm.data.minerals | orderBy:mineral track by $index'> | ||
{{ vm.getLabel(mineral) }} | ||
<button id="minerals-info-button" class=" button-small button-icon button ion-information-circled minerals-field-info-button" ng-click="vm.mineralInfoOnMainPage(mineral)"></button> | ||
</ion-item> | ||
</ion-list> | ||
<div class="padding" ng-hide="vm.data.minerals"> | ||
<span>No minerals added yet.</span> | ||
</div> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
(function () { | ||
'use strict'; | ||
|
||
angular | ||
.module('app') | ||
.directive('straboMineralTagDirective', straboMineralTagDirective); | ||
|
||
function straboMineralTagDirective() { | ||
return { | ||
'restrict': 'AE', | ||
'replace': true, | ||
'templateUrl': 'app/tag/mineral.directive.html' | ||
}; | ||
} | ||
}()); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,85 @@ | ||
<ion-modal-view class="minerals-modals"> | ||
<ion-header-bar class='bar-stable nav-title-slide-ios7' align-title='center'> | ||
<button class='button button-positive' ng-show="vm.isShowMineralList" ng-click='vm.submitMineral()'>Save | ||
</button> | ||
<button class='button button-icon icon ion-arrow-left-c' ng-hide="vm.isShowInfoOnly || vm.isShowMineralList" | ||
ng-click='vm.hideMineralInfo();'> | ||
</button> | ||
<h1 class='title'>{{ vm.modalTitle }}</h1> | ||
<div class='buttons'> | ||
<button class='icon ion-close-round close-modal-button' ng-click='vm.mineralsModal.hide()'> | ||
</button> | ||
</div> | ||
</ion-header-bar> | ||
<ion-content> | ||
<div ng-show="vm.isShowMineralList"> | ||
<div class='button-bar'> | ||
<button class='button button-full' ng-click='vm.switchMineralsForm("most_common")' | ||
ng-class="{'spot-tab-active': vm.activeState === 'most_common'}">Most Common</button> | ||
<button class='button button-full' ng-click='vm.switchMineralsForm("all")' | ||
ng-class="{'spot-tab-active': vm.activeState === 'all'}">All</button> | ||
</div> | ||
<form name='straboForm' novalidate=''> | ||
<div id='straboFormCtrlId' ng-controller='FormController as form'> | ||
<div ng-repeat='field in form.survey' class='minerals-form'> | ||
<div id='{{ field.name }}' ng-show='form.showField(field, vm.modalData)'> | ||
<ion-list class="list item-text-wrap strabo-choices-flex-container strabo-wrap" ng-class='form.setSelMultClass(field, vm.modalData)'> | ||
<ion-item class="item item-checkbox mineral-item minerals-checkbox item-minerals-checkbox item-button-right item-text-wrap minerals-item" ng-repeat='choice in form.choices | filter: { "list_name": field.type.split(" ")[1] }'> | ||
<ion-grid> | ||
<ion-row > | ||
<ion-col> | ||
<label class="checkbox mineral-checkbox"> | ||
<input type="checkbox" ng-click="form.toggleChecked(field.name, choice.name, vm.modalData)" ng-required='{{ field.required }}' | ||
ng-checked='form.isOptionChecked(field.name, choice.name, vm.modalData)'> | ||
</label> | ||
{{ choice.label }} | ||
</ion-col> | ||
</ion-row> | ||
</ion-grid> | ||
<button id="minerals-info-button" class=" button-small button-icon button ion-information-circled minerals-field-info-button" | ||
ng-click="vm.showMineralInfo(choice.name, $event)"> | ||
</button> | ||
</ion-item> | ||
</ion-list> | ||
</div> | ||
</div> | ||
</div> | ||
</form> | ||
</div> | ||
<div ng-hide="vm.isShowMineralList" class="padding"> | ||
<div ng-show="vm.mineralInfo" class="mineral-info-display"> | ||
<div class="row"> | ||
<span class="mineral-title">Mineral:</span> | ||
{{ vm.mineralInfo.Mineral }} | ||
</div> | ||
<div class="row"> | ||
<span class="mineral-title">Formula:</span> | ||
{{ vm.mineralInfo.Formula }} | ||
</div> | ||
<div class="row"> | ||
<span class="mineral-title">Crystal System:</span> | ||
{{ vm.mineralInfo["Crystal System"] }} | ||
</div> | ||
<div class="row"> | ||
<span class="mineral-title">Hardness:</span> | ||
{{ vm.mineralInfo.Hardness }} | ||
</div> | ||
<div class="row"> | ||
<span class="mineral-title">Distinguishing Features:</span> | ||
{{ vm.mineralInfo['Distinguishing Features'] }} | ||
</div> | ||
<div class="row"> | ||
<span class="mineral-title"> Occurrence:</span> | ||
{{ vm.mineralInfo.Occurrence }} | ||
</div> | ||
<div class="row"> | ||
<span class="mineral-title"> Associated Minerals:</span> | ||
{{ vm.mineralInfo['Associated Minerals'] }} | ||
</div> | ||
</div> | ||
<div ng-hide="vm.mineralInfo"> | ||
There is no description given for this mineral | ||
</div> | ||
</div> | ||
</ion-content> | ||
</ion-modal-view> |
Oops, something went wrong.