michahell/pinbored-nwjs

View on GitHub
App/views/settings.html

Summary

Maintainability
Test Coverage
<div class="screen" id="settings">

  <!-- screen title -->
  <div class="screentitle clearfix"> <!-- animated fadeIn -->
    <h6>Settings</h6>
  </div>

  <div class="section" id="list">
    
    <div class="settingsHeading clearfix">
      <h7>- overview screen settings</h7>
    </div>

    <div class="row settingsrow clearfix">

      <form class="form-horizontal">
        
        <!-- Single button -->
        <div class="form-group">
          <label for="recentAmountOptions" class="col-sm-4 control-label">set load recent bookmarks amount to: </label>
          <div class="btn-group" uib-dropdown>
            <button type="button" class="btn btn-primary dropdown-toggle" uib-dropdown-toggle ng-disabled="disabled">
              load <strong>{{newappconfig.maxRecentItems}}</strong> most recent bookmarks <span class="caret"></span>
            </button>
            <ul class="dropdown-menu" role="menu">
              <li ng-repeat="recentAmount in appconfig.maxRecentAmounts">
                <a ng-click="setRecentAmount(recentAmount)">load <strong>{{recentAmount}}</strong> most recent bookmarks</a>
              </li>
            </ul>
          </div>
        </div>

        <!-- Single button -->
        <div class="form-group">
          <label for="recentAmountOptions" class="col-sm-4 control-label">set stale check timeout: </label>
          <div class="btn-group" uib-dropdown>
            <button type="button" class="btn btn-primary dropdown-toggle" uib-dropdown-toggle ng-disabled="disabled">
              wait <strong>{{newappconfig.staleCheckTimeout / 1000}}</strong> seconds <span class="caret"></span>
            </button>
            <ul class="dropdown-menu" role="menu">
              <li ng-repeat="staleCheckTimeoutAmount in appconfig.staleCheckTimeoutAmounts">
                <a ng-click="setStaleCheckTimeout(staleCheckTimeoutAmount)">wait {{staleCheckTimeoutAmount}} seconds</a>
              </li>
            </ul>
          </div>
        </div>

      </form>

    </div>

    <div class="row settingsrow clearfix" ng-show="model.changes">

      <form class="form-horizontal">
        
        <div class="form-group">
          <div class="col-sm-7">
            <button btn-loading="busy" data-loading-text="saving changes..." type="button" 
            class="btn btn-md btn-success" ng-click="saveChanges()">save changes to settings</button>
          </div>
        </div>

      </form>

    </div>

    <div class="settingsHeading clearfix">
      <h7>- tag screen settings</h7>
    </div>

    <div class="listBackgroundMessage">
      <h5>APPLICATION SETTINGS.</h5>
    </div>

  </div>

</div>