aboutsummaryrefslogtreecommitdiff
path: root/public/javascripts/iframe.js
blob: e3296be0c6ef6e5ae42468934428d4603d0c2ae8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
const getURLOfUser = require('./getURLOfUser')

const self = {}

self._nodes = {
  iframe: document.querySelector('iframe')
}

self.viewItem = function (offset, selectedUser) {
  const url = getURLOfUser(offset, selectedUser.type, selectedUser.index + 1)
  self._nodes.iframe.src = url
}

module.exports = self