-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: dynamic DID on the web page (#40)
Signed-off-by: Fabio Pinheiro <fabiomgpinheiro@gmail.com> Signed-off-by: Shailesh Patil <shailesh.patil@iohk.io>
- Loading branch information
1 parent
c6b8034
commit 156c6fa
Showing
6 changed files
with
43 additions
and
40 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
This file was deleted.
Oops, something went wrong.
31 changes: 31 additions & 0 deletions
31
mediator/src/main/scala/io/iohk/atala/mediator/app/IndexHtml.scala
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,31 @@ | ||
package io.iohk.atala.mediator.app | ||
|
||
import zio.http.Response | ||
import fmgp.did.DID | ||
|
||
object IndexHtml { | ||
// TODO use the html.Html.fromDomElement() | ||
def html(identity: DID) = Response.html(s"""<html> | ||
|<head> | ||
| <meta charset="UTF-8"> | ||
| <title>IOHK Mediator</title> | ||
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | ||
| <meta name="did" content="${identity.did}"> | ||
| <link href="https://fonts.googleapis.com/css?family=Roboto:300,400,500" rel="stylesheet"> | ||
| <link href="https://unpkg.com/material-components-web@latest/dist/material-components-web.min.css" rel="stylesheet"> | ||
| <link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons"> | ||
| <script> | ||
| var callback = function () { | ||
| alert('A callback was triggered'); | ||
| } | ||
| </script> | ||
| <!-- My APP --> | ||
| <script type="text/javascript" src="public/webapp-fastopt-bundle.js"></script> | ||
|</head> | ||
| | ||
|<body style="margin:0;"> | ||
| <div id="app-container"></div> | ||
|</body> | ||
| | ||
|</html>""".stripMargin) | ||
} |
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