Code cleaning: all pages in App.Page.
This commit is contained in:
parent
917ac0b5ff
commit
480943d563
@ -53,19 +53,6 @@ import Data.Array as A
|
||||
import Data.Maybe (Maybe(..), maybe)
|
||||
import Data.Either (Either(..))
|
||||
import Data.Tuple (Tuple(..))
|
||||
import App.AuthenticationInterface as AI
|
||||
import App.RegistrationInterface as RI
|
||||
import App.MailValidationInterface as MVI
|
||||
import App.Log as AppLog
|
||||
import App.WS as WS
|
||||
import App.AdministrationInterface as AdminInterface
|
||||
import App.SetupInterface as SetupInterface
|
||||
import App.DomainListInterface as DomainListInterface
|
||||
import App.ZoneInterface as ZoneInterface
|
||||
import App.HomeInterface as HomeInterface
|
||||
import App.NavigationInterface as NavigationInterface
|
||||
import App.Messages.DNSManagerDaemon as DNSManager
|
||||
import App.Messages.AuthenticationDaemon as AuthD
|
||||
import Halogen as H
|
||||
import Halogen.HTML as HH
|
||||
import Halogen.HTML.Properties as HP
|
||||
@ -73,6 +60,22 @@ import Type.Proxy (Proxy(..))
|
||||
import Effect.Aff.Class (class MonadAff)
|
||||
import Data.ArrayBuffer.Types (ArrayBuffer)
|
||||
|
||||
import App.Messages.DNSManagerDaemon as DNSManager
|
||||
import App.Messages.AuthenticationDaemon as AuthD
|
||||
|
||||
import App.Log as AppLog
|
||||
import App.WS as WS
|
||||
|
||||
import App.Page.Authentication as AI
|
||||
import App.Page.Registration as RI
|
||||
import App.Page.MailValidation as MVI
|
||||
import App.Page.Administration as AdminInterface
|
||||
import App.Page.Setup as SetupInterface
|
||||
import App.Page.DomainList as DomainListInterface
|
||||
import App.Page.Zone as ZoneInterface
|
||||
import App.Page.Home as HomeInterface
|
||||
import App.Page.Navigation as NavigationInterface
|
||||
|
||||
import Web.HTML (window) as HTML
|
||||
import Web.HTML.Window (sessionStorage) as Window
|
||||
import Web.Storage.Storage as Storage
|
||||
|
@ -8,7 +8,7 @@
|
||||
- TODO: raise a user to admin (and vice versa)
|
||||
- TODO: list users (getting them slowly, otherwise it will cause problems with thousands of logins)
|
||||
-}
|
||||
module App.AdministrationInterface where
|
||||
module App.Page.Administration where
|
||||
|
||||
import Prelude (Unit, bind, discard, not, pure, show, ($), (<<<), (<>), (=<<), map, (/=))
|
||||
|
@ -1,6 +1,6 @@
|
||||
-- | `App.AuthenticationInterface` is both the authentication and password recovery interface.
|
||||
-- | TODO: token validation.
|
||||
module App.AuthenticationInterface where
|
||||
module App.Page.Authentication where
|
||||
|
||||
import Prelude (Unit, bind, discard, pure, ($), (<<<), (<>), (>), (==), map, show)
|
||||
|
@ -9,7 +9,7 @@
|
||||
-- | - ask for confirmation
|
||||
-- | - switch to the interface to show and modify the content of a Zone
|
||||
-- | - TODO: validate the domain before sending a message to `dnsmanagerd`
|
||||
module App.DomainListInterface where
|
||||
module App.Page.DomainList where
|
||||
|
||||
import Prelude (Unit, bind, discard, map, otherwise, pure, ($), (/=), (<<<), (<>), (>))
|
||||
|
@ -1,5 +1,5 @@
|
||||
-- | `App.HomeInterface` presents the website and its features.
|
||||
module App.HomeInterface where
|
||||
module App.Page.Home where
|
||||
|
||||
import Prelude (Unit, pure, unit, ($))
|
||||
|
@ -1,7 +1,7 @@
|
||||
-- | `App.MailValidationInterface` is a simple interface for mail verification.
|
||||
-- | A token is sent at registration at the provided email address.
|
||||
-- | This token has to be used to validate the email address.
|
||||
module App.MailValidationInterface where
|
||||
module App.Page.MailValidation where
|
||||
|
||||
import Prelude (Unit, bind, discard, pure, ($), (<<<), (<>), map, show)
|
||||
|
@ -3,7 +3,7 @@
|
||||
-- | This module is required since some javascript is needed to toggle display of hidden resources.
|
||||
-- | On mobile, a burger menu is displayed and hides the navigation buttons.
|
||||
-- | On desktop, there is no need for this, all the navigation buttons are displayed by default.
|
||||
module App.NavigationInterface where
|
||||
module App.Page.Navigation where
|
||||
|
||||
import Prelude (Unit, (<>), not, ($), discard, pure)
|
||||
|
@ -1,6 +1,6 @@
|
||||
-- | `App.RegistrationInterface` is a registration interface.
|
||||
-- | Registration requires a login, an email address and a password.
|
||||
module App.RegistrationInterface where
|
||||
module App.Page.Registration where
|
||||
|
||||
import Prelude (Unit, bind, discard, pure, ($), (<<<), (<>), map, show)
|
||||
|
@ -1,6 +1,6 @@
|
||||
-- | `App.SetupInterface` allows users to change their password or their email address.
|
||||
-- | Users can also erase their account.
|
||||
module App.SetupInterface where
|
||||
module App.Page.Setup where
|
||||
|
||||
import Prelude (Unit, bind, discard, pure, ($), (<<<), (==))
|
||||
|
@ -16,7 +16,7 @@
|
||||
-- | TODO: do not allow for the modification of read-only resource records.
|
||||
-- |
|
||||
-- | TODO: move all serialization code to a single module.
|
||||
module App.ZoneInterface where
|
||||
module App.Page.Zone where
|
||||
|
||||
import Prelude (Unit, unit, void
|
||||
, bind, pure
|
Loading…
Reference in New Issue
Block a user