Skip to content

Commit

Permalink
Add github link
Browse files Browse the repository at this point in the history
  • Loading branch information
UchidaMizuki committed Feb 24, 2024
1 parent 79549dc commit e154c15
Show file tree
Hide file tree
Showing 16 changed files with 191 additions and 80 deletions.
Binary file modified elm-stuff/0.19.1/Init.elmi
Binary file not shown.
Binary file modified elm-stuff/0.19.1/Init.elmo
Binary file not shown.
Binary file modified elm-stuff/0.19.1/MakeMultiples.elmi
Binary file not shown.
Binary file modified elm-stuff/0.19.1/Model.elmi
Binary file not shown.
Binary file modified elm-stuff/0.19.1/Model.elmo
Binary file not shown.
Binary file modified elm-stuff/0.19.1/Subscriptions.elmi
Binary file not shown.
Binary file modified elm-stuff/0.19.1/Update.elmi
Binary file not shown.
Binary file modified elm-stuff/0.19.1/Update.elmo
Binary file not shown.
Binary file modified elm-stuff/0.19.1/View.elmi
Binary file not shown.
Binary file modified elm-stuff/0.19.1/View.elmo
Binary file not shown.
Binary file modified elm-stuff/0.19.1/d.dat
Binary file not shown.
212 changes: 146 additions & 66 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -5550,6 +5550,8 @@
color3: {alpha: 1, blue: 202, green: 191, red: 187},
color4: {alpha: 1, blue: 100, green: 84, red: 73},
color5: {alpha: 1, blue: 72, green: 72, red: 208},
footerFontSize: 0.5,
footerHeight: 1,
gameCardBorderWidth: 0.1,
gameCardFontSize: 1,
gameCardHeight: 3,
Expand Down Expand Up @@ -6918,7 +6920,7 @@
var boxWidth = view.boxWidth;
var boxHeight = $elm$core$List$sum(
_List_fromArray(
[view.gameOpponentHandHeight, view.gameFieldHeight, view.gameInfoHeight, view.gameSelectedHandHeight, view.gamePlayerHandHeight, view.gamePlayerButtonHeight, view.boxPadding * 2, view.boxSpacing * 5]));
[view.gameOpponentHandHeight, view.gameFieldHeight, view.gameInfoHeight, view.gameSelectedHandHeight, view.gamePlayerHandHeight, view.gamePlayerButtonHeight, view.boxPadding * 2, view.boxSpacing * 5, view.footerHeight]));
var boxZoom = (_Utils_cmp(w / h, boxWidth / boxHeight) < 0) ? (w / boxWidth) : (h / boxHeight);
return _Utils_Tuple2(
_Utils_update(
Expand Down Expand Up @@ -12788,6 +12790,10 @@
A3($elm$core$List$foldl, $mdgriffith$elm_ui$Internal$Model$renderFontClassName, 'ff-', families),
families));
};
var $mdgriffith$elm_ui$Internal$Model$Fill = function (a) {
return {$: 'Fill', a: a};
};
var $mdgriffith$elm_ui$Element$fill = $mdgriffith$elm_ui$Internal$Model$Fill(1);
var $mdgriffith$elm_ui$Internal$Model$Rgba = F4(
function (a, b, c, d) {
return {$: 'Rgba', a: a, b: b, c: c, d: d};
Expand Down Expand Up @@ -13060,13 +13066,115 @@
x,
x));
};
var $mdgriffith$elm_ui$Element$Font$color = function (fontColor) {
return A2(
$mdgriffith$elm_ui$Internal$Model$StyleClass,
$mdgriffith$elm_ui$Internal$Flag$fontColor,
A3(
$mdgriffith$elm_ui$Internal$Model$Colored,
'fc-' + $mdgriffith$elm_ui$Internal$Model$formatColorClass(fontColor),
'color',
fontColor));
};
var $mdgriffith$elm_ui$Element$el = F2(
function (attrs, child) {
return A4(
$mdgriffith$elm_ui$Internal$Model$element,
$mdgriffith$elm_ui$Internal$Model$asEl,
$mdgriffith$elm_ui$Internal$Model$div,
A2(
$elm$core$List$cons,
$mdgriffith$elm_ui$Element$width($mdgriffith$elm_ui$Element$shrink),
A2(
$elm$core$List$cons,
$mdgriffith$elm_ui$Element$height($mdgriffith$elm_ui$Element$shrink),
attrs)),
$mdgriffith$elm_ui$Internal$Model$Unkeyed(
_List_fromArray(
[child])));
});
var $elm$html$Html$Attributes$href = function (url) {
return A2(
$elm$html$Html$Attributes$stringProperty,
'href',
_VirtualDom_noJavaScriptUri(url));
};
var $elm$html$Html$Attributes$rel = _VirtualDom_attribute('rel');
var $elm$html$Html$Attributes$target = $elm$html$Html$Attributes$stringProperty('target');
var $mdgriffith$elm_ui$Element$newTabLink = F2(
function (attrs, _v0) {
var url = _v0.url;
var label = _v0.label;
return A4(
$mdgriffith$elm_ui$Internal$Model$element,
$mdgriffith$elm_ui$Internal$Model$asEl,
$mdgriffith$elm_ui$Internal$Model$NodeName('a'),
A2(
$elm$core$List$cons,
$mdgriffith$elm_ui$Internal$Model$Attr(
$elm$html$Html$Attributes$href(url)),
A2(
$elm$core$List$cons,
$mdgriffith$elm_ui$Internal$Model$Attr(
$elm$html$Html$Attributes$rel('noopener noreferrer')),
A2(
$elm$core$List$cons,
$mdgriffith$elm_ui$Internal$Model$Attr(
$elm$html$Html$Attributes$target('_blank')),
A2(
$elm$core$List$cons,
$mdgriffith$elm_ui$Element$width($mdgriffith$elm_ui$Element$shrink),
A2(
$elm$core$List$cons,
$mdgriffith$elm_ui$Element$height($mdgriffith$elm_ui$Element$shrink),
A2(
$elm$core$List$cons,
$mdgriffith$elm_ui$Internal$Model$htmlClass($mdgriffith$elm_ui$Internal$Style$classes.contentCenterX + (' ' + ($mdgriffith$elm_ui$Internal$Style$classes.contentCenterY + (' ' + $mdgriffith$elm_ui$Internal$Style$classes.link)))),
attrs)))))),
$mdgriffith$elm_ui$Internal$Model$Unkeyed(
_List_fromArray(
[label])));
});
var $mdgriffith$elm_ui$Element$Font$size = function (i) {
return A2(
$mdgriffith$elm_ui$Internal$Model$StyleClass,
$mdgriffith$elm_ui$Internal$Flag$fontSize,
$mdgriffith$elm_ui$Internal$Model$FontSize(i));
};
var $mdgriffith$elm_ui$Internal$Model$Text = function (a) {
return {$: 'Text', a: a};
};
var $mdgriffith$elm_ui$Element$text = function (content) {
return $mdgriffith$elm_ui$Internal$Model$Text(content);
};
var $author$project$View$viewFooter = function (model) {
return A2(
$mdgriffith$elm_ui$Element$el,
_List_fromArray(
[
$mdgriffith$elm_ui$Element$width($mdgriffith$elm_ui$Element$fill),
$mdgriffith$elm_ui$Element$height(
$mdgriffith$elm_ui$Element$px(
A2($author$project$View$boxZoom, model, model.view.footerHeight))),
$mdgriffith$elm_ui$Element$centerX,
$mdgriffith$elm_ui$Element$centerY,
$mdgriffith$elm_ui$Element$Font$size(
A2($author$project$View$boxZoom, model, model.view.footerFontSize)),
$mdgriffith$elm_ui$Element$Font$color(
$mdgriffith$elm_ui$Element$fromRgb255(model.view.color3))
]),
A2(
$mdgriffith$elm_ui$Element$newTabLink,
_List_fromArray(
[$mdgriffith$elm_ui$Element$centerX, $mdgriffith$elm_ui$Element$centerY]),
{
label: $mdgriffith$elm_ui$Element$text('https://github.com/UchidaMizuki/make-multiples'),
url: 'https://github.com/UchidaMizuki/make-multiples'
}));
};
var $author$project$View$FieldCard = function (a) {
return {$: 'FieldCard', a: a};
};
var $mdgriffith$elm_ui$Internal$Model$Fill = function (a) {
return {$: 'Fill', a: a};
};
var $mdgriffith$elm_ui$Element$fill = $mdgriffith$elm_ui$Internal$Model$Fill(1);
var $elm$core$List$intersperse = F2(
function (sep, xs) {
if (!xs.b) {
Expand Down Expand Up @@ -13279,48 +13387,9 @@
'border-color',
clr));
};
var $mdgriffith$elm_ui$Element$Font$color = function (fontColor) {
return A2(
$mdgriffith$elm_ui$Internal$Model$StyleClass,
$mdgriffith$elm_ui$Internal$Flag$fontColor,
A3(
$mdgriffith$elm_ui$Internal$Model$Colored,
'fc-' + $mdgriffith$elm_ui$Internal$Model$formatColorClass(fontColor),
'color',
fontColor));
};
var $mdgriffith$elm_ui$Element$el = F2(
function (attrs, child) {
return A4(
$mdgriffith$elm_ui$Internal$Model$element,
$mdgriffith$elm_ui$Internal$Model$asEl,
$mdgriffith$elm_ui$Internal$Model$div,
A2(
$elm$core$List$cons,
$mdgriffith$elm_ui$Element$width($mdgriffith$elm_ui$Element$shrink),
A2(
$elm$core$List$cons,
$mdgriffith$elm_ui$Element$height($mdgriffith$elm_ui$Element$shrink),
attrs)),
$mdgriffith$elm_ui$Internal$Model$Unkeyed(
_List_fromArray(
[child])));
});
var $mdgriffith$elm_ui$Element$fillPortion = $mdgriffith$elm_ui$Internal$Model$Fill;
var $mdgriffith$elm_ui$Internal$Model$Empty = {$: 'Empty'};
var $mdgriffith$elm_ui$Element$none = $mdgriffith$elm_ui$Internal$Model$Empty;
var $mdgriffith$elm_ui$Element$Font$size = function (i) {
return A2(
$mdgriffith$elm_ui$Internal$Model$StyleClass,
$mdgriffith$elm_ui$Internal$Flag$fontSize,
$mdgriffith$elm_ui$Internal$Model$FontSize(i));
};
var $mdgriffith$elm_ui$Internal$Model$Text = function (a) {
return {$: 'Text', a: a};
};
var $mdgriffith$elm_ui$Element$text = function (content) {
return $mdgriffith$elm_ui$Internal$Model$Text(content);
};
var $mdgriffith$elm_ui$Internal$Model$BorderWidth = F5(
function (a, b, c, d, e) {
return {$: 'BorderWidth', a: a, b: b, c: c, d: d, e: e};
Expand Down Expand Up @@ -13737,31 +13806,42 @@
$mdgriffith$elm_ui$Element$column,
_List_fromArray(
[
$mdgriffith$elm_ui$Element$Background$color(
$mdgriffith$elm_ui$Element$fromRgb255(model.view.color2)),
$mdgriffith$elm_ui$Element$width(
$mdgriffith$elm_ui$Element$px(
A2($author$project$View$boxZoom, model, model.view.boxWidth))),
$mdgriffith$elm_ui$Element$centerX,
$mdgriffith$elm_ui$Element$centerY,
$mdgriffith$elm_ui$Element$padding(
A2($author$project$View$boxZoom, model, model.view.boxPadding)),
$mdgriffith$elm_ui$Element$spacing(
A2($author$project$View$boxZoom, model, model.view.boxSpacing)),
$mdgriffith$elm_ui$Element$Border$rounded(
A2($author$project$View$boxZoom, model, model.view.boxRounded)),
$mdgriffith$elm_ui$Element$Font$family(
_List_fromArray(
[model.view.gameFontFamily]))
$mdgriffith$elm_ui$Element$width($mdgriffith$elm_ui$Element$fill),
$mdgriffith$elm_ui$Element$height($mdgriffith$elm_ui$Element$fill)
]),
_List_fromArray(
[
$author$project$View$viewGameOpponentHand(model),
$author$project$View$viewGameField(model),
$author$project$View$viewGameInfo(model),
$author$project$View$viewGameSelectedHand(model),
$author$project$View$viewGamePlayerHand(model),
$author$project$View$viewGamePlayerButton(model)
A2(
$mdgriffith$elm_ui$Element$column,
_List_fromArray(
[
$mdgriffith$elm_ui$Element$Background$color(
$mdgriffith$elm_ui$Element$fromRgb255(model.view.color2)),
$mdgriffith$elm_ui$Element$width(
$mdgriffith$elm_ui$Element$px(
A2($author$project$View$boxZoom, model, model.view.boxWidth))),
$mdgriffith$elm_ui$Element$centerX,
$mdgriffith$elm_ui$Element$centerY,
$mdgriffith$elm_ui$Element$padding(
A2($author$project$View$boxZoom, model, model.view.boxPadding)),
$mdgriffith$elm_ui$Element$spacing(
A2($author$project$View$boxZoom, model, model.view.boxSpacing)),
$mdgriffith$elm_ui$Element$Border$rounded(
A2($author$project$View$boxZoom, model, model.view.boxRounded)),
$mdgriffith$elm_ui$Element$Font$family(
_List_fromArray(
[model.view.gameFontFamily]))
]),
_List_fromArray(
[
$author$project$View$viewGameOpponentHand(model),
$author$project$View$viewGameField(model),
$author$project$View$viewGameInfo(model),
$author$project$View$viewGameSelectedHand(model),
$author$project$View$viewGamePlayerHand(model),
$author$project$View$viewGamePlayerButton(model)
])),
$author$project$View$viewFooter(model)
])));
};
var $author$project$MakeMultiples$main = $elm$browser$Browser$element(
Expand Down
2 changes: 2 additions & 0 deletions src/Init.elm
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,8 @@ initModelView =
, gameCardRounded = 0.25
, gameCardFontSize = 1
, gameCardNumberFontSize = 0.625
, footerHeight = 1
, footerFontSize = 0.5
, color1 = { red = 244, green = 244, blue = 242, alpha = 1 }
, color2 = { red = 232, green = 232, blue = 232, alpha = 1 }
, color3 = { red = 187, green = 191, blue = 202, alpha = 1 }
Expand Down
3 changes: 3 additions & 0 deletions src/Model.elm
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ module Model exposing (..)
import Dict exposing (Dict)
import Element.Font as Font
import List.Nonempty exposing (Nonempty)
import Html exposing (footer)


type alias Model =
Expand Down Expand Up @@ -59,6 +60,8 @@ type alias View =
, gameCardRounded : Float
, gameCardFontSize : Float
, gameCardNumberFontSize : Float
, footerHeight : Float
, footerFontSize : Float
, color1 : Color
, color2 : Color
, color3 : Color
Expand Down
1 change: 1 addition & 0 deletions src/Update.elm
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ updateResize model w h =
, view.gamePlayerButtonHeight
, view.boxPadding * 2
, view.boxSpacing * 5
, view.footerHeight
]

boxZoom =
Expand Down
53 changes: 39 additions & 14 deletions src/View.elm
Original file line number Diff line number Diff line change
Expand Up @@ -18,21 +18,27 @@ view model =
[ Background.color <| Element.fromRgb255 model.view.color4 ]
<|
Element.column
[ Background.color <| Element.fromRgb255 model.view.color2
, Element.width <| Element.px <| boxZoom model model.view.boxWidth
, Element.centerX
, Element.centerY
, Element.padding <| boxZoom model model.view.boxPadding
, Element.spacing <| boxZoom model model.view.boxSpacing
, Border.rounded <| boxZoom model model.view.boxRounded
, Font.family [ model.view.gameFontFamily ]
[ Element.width <| Element.fill
, Element.height <| Element.fill
]
[ viewGameOpponentHand model
, viewGameField model
, viewGameInfo model
, viewGameSelectedHand model
, viewGamePlayerHand model
, viewGamePlayerButton model
[ Element.column
[ Background.color <| Element.fromRgb255 model.view.color2
, Element.width <| Element.px <| boxZoom model model.view.boxWidth
, Element.centerX
, Element.centerY
, Element.padding <| boxZoom model model.view.boxPadding
, Element.spacing <| boxZoom model model.view.boxSpacing
, Border.rounded <| boxZoom model model.view.boxRounded
, Font.family [ model.view.gameFontFamily ]
]
[ viewGameOpponentHand model
, viewGameField model
, viewGameInfo model
, viewGameSelectedHand model
, viewGamePlayerHand model
, viewGamePlayerButton model
]
, viewFooter model
]


Expand Down Expand Up @@ -175,6 +181,25 @@ viewGamePlayerButton model =
]


viewFooter : Model -> Element Msg
viewFooter model =
Element.el
[ Element.width Element.fill
, Element.height <| Element.px <| boxZoom model model.view.footerHeight
, Element.centerX
, Element.centerY
, Font.size <| boxZoom model model.view.footerFontSize
, Font.color <| Element.fromRgb255 model.view.color3
]
<|
Element.newTabLink
[ Element.centerX
, Element.centerY
]
{ url = "https://github.com/UchidaMizuki/make-multiples"
, label = Element.text "https://github.com/UchidaMizuki/make-multiples"
}

viewGameCard : Model -> GameCard -> Maybe Int -> Int -> Element Msg
viewGameCard model gameCard maybeRank cards =
let
Expand Down

0 comments on commit e154c15

Please sign in to comment.