Skip to content

Commit

Permalink
Rename 'TopLogo' to 'AppLogo'
Browse files Browse the repository at this point in the history
Renames the TopLogo component to AppLogo since the old name was
misleading, because the logo is not bound to the top of the app.
  • Loading branch information
chrismayer committed Jul 2, 2018
1 parent 7e36043 commit 4bbd891
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 22 deletions.
6 changes: 3 additions & 3 deletions src/WguApp.vue
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
</v-toolbar-items>
</wgu-app-header>

<wgu-top-logo />
<wgu-app-logo />

<wgu-map />

Expand All @@ -54,7 +54,7 @@ import OlMap from './components/ol/Map'
import InfoWindow from './components/InfoWindow'
import FeatureInfoWindow from './components/FeatureInfoWindow'
import AppHeader from './components/AppHeader'
import TopLogo from './components/TopLogo'
import AppLogo from './components/AppLogo'
import MenuButton from './components/MenuButton'
import LayerListToggleButton from './components/layerlist/ToggleButton'
import HelpWinToggleButton from './components/helpwin/ToggleButton'
Expand All @@ -69,7 +69,7 @@ export default {
'wgu-info-window': InfoWindow,
'wgu-feature-infowindow': FeatureInfoWindow,
'wgu-app-header': AppHeader,
'wgu-top-logo': TopLogo,
'wgu-app-logo': AppLogo,
'wgu-menubutton': MenuButton,
'wgu-toggle-layerlist-button': LayerListToggleButton,
'wgu-toggle-helpwin-button': HelpWinToggleButton,
Expand Down
2 changes: 1 addition & 1 deletion src/assets/css/wegue.css
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ html {
height: calc(100% - 56px);
}

.wgu-top-logo {
.wgu-app-logo {
left: 25px;
top: 45px;
}
6 changes: 3 additions & 3 deletions src/components/TopLogo.vue → src/components/AppLogo.vue
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<v-avatar
:size="logoSize"
:tile="true"
class="wgu-top-logo"
class="wgu-app-logo"
>
<img :src="logoSrc" alt="App Logo">
</v-avatar>
Expand All @@ -13,7 +13,7 @@
<script>
export default {
name: 'wgu-top-logo',
name: 'wgu-app-logo',
data () {
return {
logoSrc: this.$appConfig.logo,
Expand All @@ -26,7 +26,7 @@ export default {
<!-- Add "scoped" attribute to limit CSS to this component only -->
<style>
.wgu-top-logo {
.wgu-app-logo {
position: absolute;
z-index: 1000;
border: 2px solid white;
Expand Down
15 changes: 15 additions & 0 deletions test/unit/specs/AppLogo.spec.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import Vue from 'vue'
import AppLogo from '@/components/AppLogo'

describe('AppLogo.vue', () => {
it('should render an <img> tag', () => {
const Constructor = Vue.extend(AppLogo);
const AppLogoComponent = new Constructor({
logoSrc: 'foosrc'
}).$mount();

// assert that component has an img tag
const avatarImg = AppLogoComponent.$el.querySelector('img');
expect(avatarImg.src !== null).to.equal(true);
});
});
15 changes: 0 additions & 15 deletions test/unit/specs/TopLogo.spec.js

This file was deleted.

0 comments on commit 4bbd891

Please sign in to comment.