add modal window UI
This commit is contained in:
@@ -53,3 +53,5 @@ MonoBehaviour:
|
||||
m_Color: {r: 0.09803922, g: 0.16470589, b: 0.3372549, a: 1}
|
||||
- m_Name:
|
||||
m_Color: {r: 0.18431373, g: 0.21176471, b: 0.2509804, a: 1}
|
||||
- m_Name:
|
||||
m_Color: {r: 0, g: 0, b: 0, a: 1}
|
||||
|
||||
@@ -11,6 +11,7 @@ GameObject:
|
||||
- component: {fileID: 3806516703089782041}
|
||||
- component: {fileID: 3806516703089782043}
|
||||
- component: {fileID: 3806516703089782040}
|
||||
- component: {fileID: 8262234233815637061}
|
||||
m_Layer: 5
|
||||
m_Name: Text (TMP)
|
||||
m_TagString: Untagged
|
||||
@@ -25,17 +26,17 @@ RectTransform:
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 3806516703089782046}
|
||||
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
|
||||
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children: []
|
||||
m_Father: {fileID: 3806516704876462308}
|
||||
m_RootOrder: 1
|
||||
m_Father: {fileID: 3806516703338386383}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 1, y: 1}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 0, y: 0}
|
||||
m_AnchoredPosition: {x: 21.18, y: 0}
|
||||
m_SizeDelta: {x: 0, y: 0}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!222 &3806516703089782043
|
||||
@@ -135,6 +136,20 @@ MonoBehaviour:
|
||||
m_hasFontAssetChanged: 0
|
||||
m_baseMaterial: {fileID: 0}
|
||||
m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
|
||||
--- !u!114 &8262234233815637061
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 3806516703089782046}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 3245ec927659c4140ac4f8d17403cc18, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_HorizontalFit: 2
|
||||
m_VerticalFit: 2
|
||||
--- !u!1 &3806516703338386380
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -148,6 +163,8 @@ GameObject:
|
||||
- component: {fileID: 3806516703338386376}
|
||||
- component: {fileID: 3806516703338386377}
|
||||
- component: {fileID: 3806516703338386382}
|
||||
- component: {fileID: 8115133298804345861}
|
||||
- component: {fileID: 2413812458207048714}
|
||||
m_Layer: 5
|
||||
m_Name: Background
|
||||
m_TagString: Untagged
|
||||
@@ -166,13 +183,14 @@ RectTransform:
|
||||
m_LocalPosition: {x: 0, y: 0, z: 0}
|
||||
m_LocalScale: {x: 1, y: 1, z: 1}
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children: []
|
||||
m_Children:
|
||||
- {fileID: 3806516703089782041}
|
||||
m_Father: {fileID: 3806516704876462308}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
m_AnchorMin: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 1, y: 1}
|
||||
m_AnchoredPosition: {x: 0, y: 0}
|
||||
m_AnchorMax: {x: 0, y: 0}
|
||||
m_AnchoredPosition: {x: -42.48101, y: 0}
|
||||
m_SizeDelta: {x: 0, y: 0}
|
||||
m_Pivot: {x: 0.5, y: 0.5}
|
||||
--- !u!222 &3806516703338386379
|
||||
@@ -243,6 +261,46 @@ MonoBehaviour:
|
||||
m_EffectColor: {r: 0, g: 0, b: 0, a: 0.5}
|
||||
m_EffectDistance: {x: 1, y: -1}
|
||||
m_UseGraphicAlpha: 1
|
||||
--- !u!114 &8115133298804345861
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 3806516703338386380}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 30649d3a9faa99c48a7b1166b86bf2a0, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Padding:
|
||||
m_Left: 5
|
||||
m_Right: 5
|
||||
m_Top: 5
|
||||
m_Bottom: 5
|
||||
m_ChildAlignment: 4
|
||||
m_Spacing: 0
|
||||
m_ChildForceExpandWidth: 1
|
||||
m_ChildForceExpandHeight: 1
|
||||
m_ChildControlWidth: 0
|
||||
m_ChildControlHeight: 0
|
||||
m_ChildScaleWidth: 0
|
||||
m_ChildScaleHeight: 0
|
||||
m_ReverseArrangement: 0
|
||||
--- !u!114 &2413812458207048714
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 3806516703338386380}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 3245ec927659c4140ac4f8d17403cc18, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_HorizontalFit: 2
|
||||
m_VerticalFit: 2
|
||||
--- !u!1 &3806516704876462309
|
||||
GameObject:
|
||||
m_ObjectHideFlags: 0
|
||||
@@ -253,6 +311,7 @@ GameObject:
|
||||
m_Component:
|
||||
- component: {fileID: 3806516704876462308}
|
||||
- component: {fileID: 3806516704876462311}
|
||||
- component: {fileID: 327755658309153619}
|
||||
m_Layer: 5
|
||||
m_Name: button
|
||||
m_TagString: Untagged
|
||||
@@ -273,7 +332,6 @@ RectTransform:
|
||||
m_ConstrainProportionsScale: 0
|
||||
m_Children:
|
||||
- {fileID: 3806516703338386383}
|
||||
- {fileID: 3806516703089782041}
|
||||
m_Father: {fileID: 0}
|
||||
m_RootOrder: 0
|
||||
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
|
||||
@@ -326,3 +384,29 @@ MonoBehaviour:
|
||||
m_OnClick:
|
||||
m_PersistentCalls:
|
||||
m_Calls: []
|
||||
--- !u!114 &327755658309153619
|
||||
MonoBehaviour:
|
||||
m_ObjectHideFlags: 0
|
||||
m_CorrespondingSourceObject: {fileID: 0}
|
||||
m_PrefabInstance: {fileID: 0}
|
||||
m_PrefabAsset: {fileID: 0}
|
||||
m_GameObject: {fileID: 3806516704876462309}
|
||||
m_Enabled: 1
|
||||
m_EditorHideFlags: 0
|
||||
m_Script: {fileID: 11500000, guid: 30649d3a9faa99c48a7b1166b86bf2a0, type: 3}
|
||||
m_Name:
|
||||
m_EditorClassIdentifier:
|
||||
m_Padding:
|
||||
m_Left: 0
|
||||
m_Right: 0
|
||||
m_Top: 0
|
||||
m_Bottom: 0
|
||||
m_ChildAlignment: 0
|
||||
m_Spacing: 0
|
||||
m_ChildForceExpandWidth: 1
|
||||
m_ChildForceExpandHeight: 1
|
||||
m_ChildControlWidth: 0
|
||||
m_ChildControlHeight: 0
|
||||
m_ChildScaleWidth: 0
|
||||
m_ChildScaleHeight: 0
|
||||
m_ReverseArrangement: 0
|
||||
|
||||
+1963
-40
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 04665103e60379b4b97c90b7437ad25f
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,61 @@
|
||||
using System;
|
||||
using TMPro;
|
||||
using UnityEngine;
|
||||
using UnityEngine.UI;
|
||||
|
||||
public class ModalWindowPanel : MonoBehaviour
|
||||
{
|
||||
[Header("Header")]
|
||||
[SerializeField]
|
||||
private Transform _hederArea;
|
||||
|
||||
[SerializeField]
|
||||
private Transform _titleField;
|
||||
|
||||
[Header("Content")]
|
||||
[SerializeField]
|
||||
private Transform _contentArea;
|
||||
|
||||
[SerializeField]
|
||||
private Transform _verticalLayoutArea;
|
||||
|
||||
[SerializeField]
|
||||
private Image _heroImage;
|
||||
|
||||
[SerializeField]
|
||||
private TextMeshProUGUI _heroText;
|
||||
|
||||
[Space()]
|
||||
[SerializeField]
|
||||
private Transform _horizontalLayoutArea;
|
||||
|
||||
[SerializeField]
|
||||
private Image _iconImage;
|
||||
|
||||
[SerializeField]
|
||||
private TextMeshProUGUI _iconText;
|
||||
|
||||
[Header("Footer")]
|
||||
[SerializeField]
|
||||
private Transform _footerArea;
|
||||
|
||||
[SerializeField]
|
||||
private Button _confirmButton;
|
||||
|
||||
[SerializeField]
|
||||
private Button _declineButton;
|
||||
|
||||
private Action onConfirmAction;
|
||||
private Action onDeclineAction;
|
||||
|
||||
public void Confirm()
|
||||
{
|
||||
onConfirmAction?.Invoke();
|
||||
// Close();
|
||||
}
|
||||
public void Decline()
|
||||
{
|
||||
onDeclineAction?.Invoke();
|
||||
//Close();
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 1c8cd26649ff30a4ea72d44d9bcd0edf
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
Reference in New Issue
Block a user