koylu-vampir-design 1.0.25 → 1.0.27

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (82) hide show
  1. package/dist/.watchman-cookie-Oktay-MacBook-Pro.local-562-3809 +0 -0
  2. package/dist/Alerts/AlertProvider.d.ts.map +1 -1
  3. package/dist/Alerts/AlertProvider.js +6 -7
  4. package/dist/Buttons/GiftFrame.d.ts +1 -0
  5. package/dist/Buttons/GiftFrame.d.ts.map +1 -1
  6. package/dist/Buttons/GiftFrame.js +4 -3
  7. package/dist/Buttons/MenuButton.d.ts.map +1 -1
  8. package/dist/Buttons/MenuButton.js +15 -15
  9. package/dist/GameParts/GiftPackBar.d.ts +10 -0
  10. package/dist/GameParts/GiftPackBar.d.ts.map +1 -1
  11. package/dist/GameParts/GiftPackBar.js +33 -40
  12. package/dist/Markets/MarketInfo.d.ts +4 -0
  13. package/dist/Markets/MarketInfo.d.ts.map +1 -1
  14. package/dist/Markets/MarketInfo.js +18 -14
  15. package/dist/Menus/MenuOptions.d.ts +1 -0
  16. package/dist/Menus/MenuOptions.d.ts.map +1 -1
  17. package/dist/Menus/MenuOptions.js +28 -18
  18. package/dist/Menus/MenuUserItem.d.ts +2 -0
  19. package/dist/Menus/MenuUserItem.d.ts.map +1 -1
  20. package/dist/Menus/MenuUserItem.js +12 -4
  21. package/dist/Messages/MessageList.d.ts +0 -1
  22. package/dist/Messages/MessageList.d.ts.map +1 -1
  23. package/dist/Messages/MessageList.js +24 -77
  24. package/dist/Navbars/UserBar.d.ts +1 -0
  25. package/dist/Navbars/UserBar.d.ts.map +1 -1
  26. package/dist/Navbars/UserBar.js +16 -12
  27. package/dist/Players/ArtistView.d.ts +46 -0
  28. package/dist/Players/ArtistView.d.ts.map +1 -0
  29. package/dist/Players/ArtistView.js +205 -0
  30. package/dist/Players/GuestLights.d.ts +6 -0
  31. package/dist/Players/GuestLights.d.ts.map +1 -0
  32. package/dist/Players/GuestLights.js +170 -0
  33. package/dist/Players/GuestView copy.d.ts +46 -0
  34. package/dist/Players/GuestView copy.d.ts.map +1 -0
  35. package/dist/Players/GuestView copy.js +181 -0
  36. package/dist/Players/GuestView.d.ts +46 -0
  37. package/dist/Players/GuestView.d.ts.map +1 -0
  38. package/dist/Players/GuestView.js +195 -0
  39. package/dist/Players/PlayerBg.d.ts +1 -0
  40. package/dist/Players/PlayerBg.d.ts.map +1 -1
  41. package/dist/Players/PlayerBg.js +5 -5
  42. package/dist/Players/PlayerGifts.d.ts.map +1 -1
  43. package/dist/Players/PlayerGifts.js +15 -10
  44. package/dist/Players/PlayerLayout copy.d.ts +16 -0
  45. package/dist/Players/PlayerLayout copy.d.ts.map +1 -0
  46. package/dist/Players/PlayerLayout copy.js +24 -0
  47. package/dist/Players/PlayerName.d.ts +2 -0
  48. package/dist/Players/PlayerName.d.ts.map +1 -1
  49. package/dist/Players/PlayerName.js +9 -6
  50. package/dist/Players/PlayerNumber.d.ts +2 -0
  51. package/dist/Players/PlayerNumber.d.ts.map +1 -1
  52. package/dist/Players/PlayerNumber.js +15 -6
  53. package/dist/Players/PlayerPreview.d.ts.map +1 -1
  54. package/dist/Players/PlayerPreview.js +30 -33
  55. package/dist/Players/PlayerView copy.d.ts +45 -0
  56. package/dist/Players/PlayerView copy.d.ts.map +1 -0
  57. package/dist/Players/PlayerView copy.js +212 -0
  58. package/dist/Players/PlayerView.d.ts +1 -0
  59. package/dist/Players/PlayerView.d.ts.map +1 -1
  60. package/dist/Players/PlayerView.js +4 -1
  61. package/dist/Players/SceneLayout.d.ts +18 -0
  62. package/dist/Players/SceneLayout.d.ts.map +1 -0
  63. package/dist/Players/SceneLayout.js +140 -0
  64. package/dist/Players/index.d.ts +2 -0
  65. package/dist/Players/index.d.ts.map +1 -1
  66. package/dist/Players/index.js +5 -1
  67. package/dist/Roles/RoleInfoBox.d.ts +1 -0
  68. package/dist/Roles/RoleInfoBox.d.ts.map +1 -1
  69. package/dist/Roles/RoleInfoBox.js +20 -12
  70. package/dist/Screens/ScreenBase.d.ts +2 -0
  71. package/dist/Screens/ScreenBase.d.ts.map +1 -1
  72. package/dist/Screens/ScreenBase.js +3 -1
  73. package/dist/Screens/ScreenHeader.d.ts +2 -0
  74. package/dist/Screens/ScreenHeader.d.ts.map +1 -1
  75. package/dist/Screens/ScreenHeader.js +14 -11
  76. package/dist/Utils/FadeImage.d.ts +1 -0
  77. package/dist/Utils/FadeImage.d.ts.map +1 -1
  78. package/dist/Utils/FadeImage.js +11 -1
  79. package/dist/index.d.ts +8 -8
  80. package/dist/index.d.ts.map +1 -1
  81. package/dist/index.js +3 -2
  82. package/package.json +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"AlertProvider.d.ts","sourceRoot":"","sources":["../../src/Alerts/AlertProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAO1B,aAAK,gBAAgB,GAAG;IACtB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,CAAC,GAAG,KAAA,KAAK,IAAI,CAAC;IACzB,QAAQ,CAAC,EAAE,CAAC,GAAG,KAAA,KAAK,IAAI,CAAC;IACzB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,CAAC;AAEF,aAAK,SAAS,GAAG;IACf,SAAS,EAAE,CAAC,OAAO,CAAC,EAAE,GAAG,EAAE,OAAO,CAAC,EAAE,gBAAgB,KAAK,IAAI,CAAC;IAC/D,YAAY,CAAC,EAAE,CAAC,OAAO,CAAC,EAAE,GAAG,EAAE,OAAO,CAAC,EAAE,gBAAgB,KAAK,OAAO,CAAC,GAAG,CAAC,CAAC;IAC3E,WAAW,CAAC,EAAE,CAAC,OAAO,CAAC,EAAE,GAAG,EAAE,UAAU,CAAC,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,gBAAgB,KAAK,OAAO,CAAC,GAAG,CAAC,CAAC;IAC/F,UAAU,CAAC,EAAE,CAAC,OAAO,CAAC,EAAE,GAAG,EAAE,KAAK,CAAC,EAAE,KAAK,CAAC,GAAG,CAAC,EAAE,OAAO,CAAC,EAAE,gBAAgB,KAAK,OAAO,CAAC,GAAG,CAAC,CAAC;IAC7F,UAAU,EAAE,MAAM,IAAI,CAAC;CACxB,CAAC;AAIF,eAAO,MAAM,YAAY,0BAKvB,CAAC;AAEH,eAAO,MAAM,QAAQ,iBAAuC,CAAC;AAC7D,aAAK,UAAU,GAAG,EAAE,CAAA;AAEpB,eAAO,MAAM,aAAa,EAAE,KAAK,CAAC,EAAE,CAAC,UAAU,CAwE9C,CAAC"}
1
+ {"version":3,"file":"AlertProvider.d.ts","sourceRoot":"","sources":["../../src/Alerts/AlertProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAO1B,aAAK,gBAAgB,GAAG;IACtB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,CAAC,GAAG,KAAA,KAAK,IAAI,CAAC;IACzB,QAAQ,CAAC,EAAE,CAAC,GAAG,KAAA,KAAK,IAAI,CAAC;IACzB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,CAAC;AAEF,aAAK,SAAS,GAAG;IACf,SAAS,EAAE,CAAC,OAAO,CAAC,EAAE,GAAG,EAAE,OAAO,CAAC,EAAE,gBAAgB,KAAK,IAAI,CAAC;IAC/D,YAAY,CAAC,EAAE,CAAC,OAAO,CAAC,EAAE,GAAG,EAAE,OAAO,CAAC,EAAE,gBAAgB,KAAK,OAAO,CAAC,GAAG,CAAC,CAAC;IAC3E,WAAW,CAAC,EAAE,CACZ,OAAO,CAAC,EAAE,GAAG,EACb,UAAU,CAAC,EAAE,MAAM,EACnB,OAAO,CAAC,EAAE,gBAAgB,KACvB,OAAO,CAAC,GAAG,CAAC,CAAC;IAClB,UAAU,CAAC,EAAE,CACX,OAAO,CAAC,EAAE,GAAG,EACb,KAAK,CAAC,EAAE,KAAK,CAAC,GAAG,CAAC,EAClB,OAAO,CAAC,EAAE,gBAAgB,KACvB,OAAO,CAAC,GAAG,CAAC,CAAC;IAClB,UAAU,EAAE,MAAM,IAAI,CAAC;CACxB,CAAC;AAIF,eAAO,MAAM,YAAY,0BAGvB,CAAC;AAEH,eAAO,MAAM,QAAQ,iBAAuC,CAAC;AAC7D,aAAK,UAAU,GAAG,EAAE,CAAC;AAErB,eAAO,MAAM,aAAa,EAAE,KAAK,CAAC,EAAE,CAAC,UAAU,CAsF9C,CAAC"}
@@ -12,10 +12,8 @@ const AlertSelectContent_1 = require("./AlertSelectContent");
12
12
  const Utils_1 = require("../Utils");
13
13
  const MODAL_PRESENTATION_STYLE = "pageSheet";
14
14
  exports.AlertContext = react_1.default.createContext({
15
- showAlert: () => {
16
- },
17
- closeAlert: () => {
18
- }
15
+ showAlert: () => { },
16
+ closeAlert: () => { },
19
17
  });
20
18
  const useAlert = () => react_1.default.useContext(exports.AlertContext);
21
19
  exports.useAlert = useAlert;
@@ -60,8 +58,9 @@ const AlertProvider = ({ children }) => {
60
58
  return (react_1.default.createElement(exports.AlertContext.Provider, { value: { showAlert, showQuestion, closeAlert, showConfirm, showSelect } },
61
59
  children,
62
60
  react_1.default.createElement(react_native_1.Modal, { visible: isVisible, onRequestClose: () => setVisible(false), animationType: "slide", presentationStyle: Utils_1.Performance.ramAvailable(2) ? "pageSheet" : undefined, transparent: true },
63
- type === "alert" && react_1.default.createElement(AlertContent_1.AlertContent, { options: options }, content),
64
- type === "question" && react_1.default.createElement(AlertQuestionContent_1.AlertQuestionContent, { options: options }, content),
65
- type === "select" && react_1.default.createElement(AlertSelectContent_1.AlertSelectContent, { options: options }, content))));
61
+ react_1.default.createElement(react_native_1.View, { style: { flex: 1, backgroundColor: "rgba(0,0,0,0.5)" } },
62
+ type === "alert" && (react_1.default.createElement(AlertContent_1.AlertContent, { options: options }, content)),
63
+ type === "question" && (react_1.default.createElement(AlertQuestionContent_1.AlertQuestionContent, { options: options }, content)),
64
+ type === "select" && (react_1.default.createElement(AlertSelectContent_1.AlertSelectContent, { options: options }, content))))));
66
65
  };
67
66
  exports.AlertProvider = AlertProvider;
@@ -4,6 +4,7 @@ declare type Props = {
4
4
  selected?: boolean;
5
5
  onPress: (event?: GestureResponderEvent) => void;
6
6
  gift: string;
7
+ size?: number;
7
8
  };
8
9
  export declare const GiftFrame: React.FC<Props>;
9
10
  export {};
@@ -1 +1 @@
1
- {"version":3,"file":"GiftFrame.d.ts","sourceRoot":"","sources":["../../src/Buttons/GiftFrame.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EACL,qBAAqB,EAKtB,MAAM,cAAc,CAAC;AAKtB,aAAK,KAAK,GAAG;IACX,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,OAAO,EAAE,CAAC,KAAK,CAAC,EAAE,qBAAqB,KAAK,IAAI,CAAC;IACjD,IAAI,EAAE,MAAM,CAAC;CACd,CAAC;AAEF,eAAO,MAAM,SAAS,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,CA0BrC,CAAC"}
1
+ {"version":3,"file":"GiftFrame.d.ts","sourceRoot":"","sources":["../../src/Buttons/GiftFrame.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EACL,qBAAqB,EAKtB,MAAM,cAAc,CAAC;AAKtB,aAAK,KAAK,GAAG;IACX,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,OAAO,EAAE,CAAC,KAAK,CAAC,EAAE,qBAAqB,KAAK,IAAI,CAAC;IACjD,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,eAAO,MAAM,SAAS,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,CAkCrC,CAAC"}
@@ -8,19 +8,20 @@ const react_1 = __importDefault(require("react"));
8
8
  const react_native_1 = require("react-native");
9
9
  const Views_1 = require("../Views");
10
10
  const Utils_1 = require("../Utils");
11
- const GiftFrame = ({ selected, onPress, gift }) => {
11
+ const GiftFrame = ({ selected, onPress, gift, size = 70, }) => {
12
12
  const renderIcon = () => {
13
13
  if (!gift.indexOf("a-")) {
14
14
  console.log("SRC", Utils_1.Assets.getSource("gift", gift));
15
- return (react_1.default.createElement(react_native_1.Image, { source: Utils_1.Assets.getSource("gift", gift, "small"), accessibilityLabel: gift.replace("a-", ""), style: styles.giftImage }));
15
+ return (react_1.default.createElement(react_native_1.Image, { source: Utils_1.Assets.getSource("gift", gift, "small"), accessibilityLabel: gift.replace("a-", ""), style: [styles.giftImage, { width: size - 15, height: size - 15 }] }));
16
16
  }
17
17
  return react_1.default.createElement(react_native_1.Text, { style: styles.giftText }, gift);
18
18
  };
19
19
  return (react_1.default.createElement(Views_1.TouchableView, { out: selected, onPress: onPress, style: [
20
20
  styles.giftFrameWrapper,
21
+ { width: size, height: size },
21
22
  selected ? styles.giftFrameWrapperSelected : {},
22
23
  ] },
23
- react_1.default.createElement(react_native_1.View, { style: styles.giftFrame }, renderIcon())));
24
+ react_1.default.createElement(react_native_1.View, { style: [styles.giftFrame, { width: size - 10, height: size - 10 }] }, renderIcon())));
24
25
  };
25
26
  exports.GiftFrame = GiftFrame;
26
27
  const styles = react_native_1.StyleSheet.create({
@@ -1 +1 @@
1
- {"version":3,"file":"MenuButton.d.ts","sourceRoot":"","sources":["../../src/Buttons/MenuButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAc,qBAAqB,EAAE,SAAS,EAAoB,MAAM,cAAc,CAAC;AAK9F,oBAAY,eAAe,GAAG;IAC5B,KAAK,CAAC,EAAE,SAAS,CAAC,GAAG,CAAC,CAAC;IACvB,WAAW,CAAC,EAAE,SAAS,CAAC,GAAG,CAAC,CAAC;IAC7B,SAAS,CAAC,EAAE,SAAS,CAAC,GAAG,CAAC,CAAC;IAC3B,SAAS,CAAC,EAAE,SAAS,CAAC,GAAG,CAAC,CAAC;IAC3B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,CAAC,KAAK,CAAC,EAAE,qBAAqB,KAAK,IAAI,CAAC;IACjD,WAAW,CAAC,EAAE,CAAC,KAAK,CAAC,EAAE,qBAAqB,KAAK,IAAI,CAAC;IACtD,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,GAAG,CAAC,EAAE,OAAO,CAAC;IACd,cAAc,CAAC,EAAE,KAAK,CAAC,SAAS,GAAG,KAAK,CAAC,EAAE,GAAG,GAAG,CAAC,OAAO,GAAG,MAAM,GAAG,MAAM,CAAC;CAC7E,CAAC;AAEF,eAAO,MAAM,UAAU,EAAE,KAAK,CAAC,EAAE,CAAC,eAAe,CAwGhD,CAAC"}
1
+ {"version":3,"file":"MenuButton.d.ts","sourceRoot":"","sources":["../../src/Buttons/MenuButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAEL,qBAAqB,EACrB,SAAS,EAGV,MAAM,cAAc,CAAC;AAKtB,oBAAY,eAAe,GAAG;IAC5B,KAAK,CAAC,EAAE,SAAS,CAAC,GAAG,CAAC,CAAC;IACvB,WAAW,CAAC,EAAE,SAAS,CAAC,GAAG,CAAC,CAAC;IAC7B,SAAS,CAAC,EAAE,SAAS,CAAC,GAAG,CAAC,CAAC;IAC3B,SAAS,CAAC,EAAE,SAAS,CAAC,GAAG,CAAC,CAAC;IAC3B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,CAAC,KAAK,CAAC,EAAE,qBAAqB,KAAK,IAAI,CAAC;IACjD,WAAW,CAAC,EAAE,CAAC,KAAK,CAAC,EAAE,qBAAqB,KAAK,IAAI,CAAC;IACtD,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,GAAG,CAAC,EAAE,OAAO,CAAC;IACd,cAAc,CAAC,EAAE,KAAK,CAAC,SAAS,GAAG,KAAK,CAAC,EAAE,GAAG,GAAG,CAAC,OAAO,GAAG,MAAM,GAAG,MAAM,CAAC;CAC7E,CAAC;AAEF,eAAO,MAAM,UAAU,EAAE,KAAK,CAAC,EAAE,CAAC,eAAe,CAsGhD,CAAC"}
@@ -9,7 +9,7 @@ const react_native_1 = require("react-native");
9
9
  const Views_1 = require("../Views");
10
10
  const Icon_1 = require("../Utils/Icon");
11
11
  const Themes_1 = require("../Themes");
12
- const MenuButton = ({ children, style = {}, size, iconStyle, onPress, onLongPress, textStyle, iconFamily, type, buttonStyle, selected, icon, disabled, out = true, rightComponent }) => {
12
+ const MenuButton = ({ children, style = {}, size, iconStyle, onPress, onLongPress, textStyle, iconFamily, type, buttonStyle, selected, icon, disabled, out = true, rightComponent, }) => {
13
13
  const buttonStyles = [styles.button];
14
14
  const textStyles = [styles.text];
15
15
  const iconStyles = [styles.icon];
@@ -69,7 +69,7 @@ const MenuButton = ({ children, style = {}, size, iconStyle, onPress, onLongPres
69
69
  }
70
70
  return (react_1.default.createElement(Views_1.TouchableView, { out: out, style: [...buttonStyles, style, disabled && styles.disabled], wrapperStyle: {
71
71
  marginLeft: style.marginLeft,
72
- marginRight: style.marginRight
72
+ marginRight: style.marginRight,
73
73
  }, disabled: disabled, onPress: onPress, onLongPress: onLongPress },
74
74
  icon && (react_1.default.createElement(Icon_1.Icon, { name: icon, color: "#ffffff", font: iconFamily || "IconIon", size: 16, style: [...iconStyles, iconStyle] })),
75
75
  react_1.default.createElement(react_native_1.Text, { style: [...textStyles, textStyle] }, children),
@@ -95,61 +95,61 @@ const styles = react_native_1.StyleSheet.create({
95
95
  shadowColor: "#000000",
96
96
  shadowOffset: {
97
97
  width: 4,
98
- height: 6
98
+ height: 6,
99
99
  },
100
100
  shadowOpacity: 0.25,
101
101
  shadowRadius: 5,
102
- elevation: 5
102
+ elevation: 5,
103
103
  },
104
104
  lightBlue: {
105
105
  backgroundColor: "#4BC3F6",
106
106
  width: "auto",
107
- height: 44
107
+ height: 44,
108
108
  },
109
109
  disabled: {
110
110
  backgroundColor: "#aaaaaa",
111
111
  borderColor: "#cccccc",
112
112
  shadowOpacity: 0,
113
113
  shadowRadius: 0,
114
- elevation: 0
114
+ elevation: 0,
115
115
  },
116
116
  icon: {
117
117
  width: 18,
118
118
  height: 18,
119
119
  marginRight: 6,
120
- marginLeft: 0
120
+ marginLeft: 0,
121
121
  },
122
122
  text: {
123
123
  color: "white",
124
124
  textAlign: "center",
125
125
  fontFamily: "Righteous-Regular",
126
126
  fontSize: 14,
127
- fontWeight: "bold"
127
+ fontWeight: "bold",
128
128
  },
129
129
  lightBlueText: {
130
130
  fontSize: 13,
131
- color: "#ffffff"
131
+ color: "#ffffff",
132
132
  },
133
133
  outline: {
134
134
  backgroundColor: "#88888833",
135
135
  borderColor: "#ee7461",
136
136
  borderWidth: 3,
137
- shadowOpacity: 0
137
+ shadowOpacity: 0,
138
138
  },
139
139
  outlineText: {
140
- color: "#ee7461"
140
+ color: "#ee7461",
141
141
  },
142
142
  medium: {
143
143
  height: 44,
144
144
  width: "auto",
145
- paddingHorizontal: 25
145
+ paddingHorizontal: 25,
146
146
  },
147
147
  small: {
148
148
  height: 28,
149
149
  width: "auto",
150
- paddingHorizontal: 20
150
+ paddingHorizontal: 20,
151
151
  },
152
152
  smallText: {
153
- fontSize: 13
154
- }
153
+ fontSize: 13,
154
+ },
155
155
  });
@@ -9,6 +9,16 @@ declare type Props = {
9
9
  selected?: string;
10
10
  remain?: number;
11
11
  };
12
+ declare type ItemProps = {
13
+ item: string;
14
+ onSelect: (item: string, pack: string) => void;
15
+ pack: {
16
+ [key: string]: any;
17
+ };
18
+ isEmpty: boolean;
19
+ isSelected: boolean;
20
+ };
21
+ export declare const GiftPackItem: React.FC<ItemProps>;
12
22
  export declare const GiftPackBar: React.FC<Props>;
13
23
  export {};
14
24
  //# sourceMappingURL=GiftPackBar.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"GiftPackBar.d.ts","sourceRoot":"","sources":["../../src/GameParts/GiftPackBar.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAM1B,aAAK,KAAK,GAAG;IACX,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IAC/C,UAAU,EAAE,CAAC,IAAI,EAAE,GAAG,KAAK,IAAI,CAAC;IAChC,IAAI,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;KAAE,CAAC;IAC7B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF,eAAO,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,CAsHvC,CAAC"}
1
+ {"version":3,"file":"GiftPackBar.d.ts","sourceRoot":"","sources":["../../src/GameParts/GiftPackBar.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAM1B,aAAK,KAAK,GAAG;IACX,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IAC/C,UAAU,EAAE,CAAC,IAAI,EAAE,GAAG,KAAK,IAAI,CAAC;IAChC,IAAI,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;KAAE,CAAC;IAC7B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF,aAAK,SAAS,GAAG;IACf,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IAC/C,IAAI,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;KAAE,CAAC;IAC7B,OAAO,EAAE,OAAO,CAAC;IACjB,UAAU,EAAE,OAAO,CAAC;CACrB,CAAC;AAEF,eAAO,MAAM,YAAY,EAAE,KAAK,CAAC,EAAE,CAAC,SAAS,CA4B5C,CAAC;AAEF,eAAO,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,CAyFvC,CAAC"}
@@ -3,12 +3,22 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.GiftPackBar = void 0;
6
+ exports.GiftPackBar = exports.GiftPackItem = void 0;
7
7
  const react_1 = __importDefault(require("react"));
8
8
  const react_native_1 = require("react-native");
9
9
  const Buttons_1 = require("../Buttons");
10
10
  const Views_1 = require("../Views");
11
11
  const Utils_1 = require("../Utils");
12
+ const GiftPackItem = ({ item, onSelect, pack, isEmpty, isSelected, }) => {
13
+ return react_1.default.useMemo(() => {
14
+ let giftElement = react_1.default.createElement(react_native_1.Text, { style: { fontSize: 14 } }, item);
15
+ if (item.indexOf("a") === 0) {
16
+ giftElement = (react_1.default.createElement(react_native_1.Image, { style: [{ width: 24, height: 24 }, { opacity: isEmpty ? 0.7 : 1 }], accessibilityLabel: item.toString(), source: Utils_1.Assets.getSource("gift", item, "icon") }));
17
+ }
18
+ return (react_1.default.createElement(Views_1.TouchableView, { out: true, onPress: () => onSelect(item, pack.id), style: [styles.button, isSelected ? styles.buttonSelected : {}] }, giftElement));
19
+ }, [isSelected, isEmpty]);
20
+ };
21
+ exports.GiftPackItem = GiftPackItem;
12
22
  const GiftPackBar = ({ title, onSelect, onBuyPress, pack, selected, remain, }) => {
13
23
  const gifts = [...pack.gifts] || [];
14
24
  const customGifts = [];
@@ -18,44 +28,27 @@ const GiftPackBar = ({ title, onSelect, onBuyPress, pack, selected, remain, }) =
18
28
  }
19
29
  // ad
20
30
  const loaded = true;
21
- return (react_1.default.createElement(react_native_1.View, { style: styles.wrapper },
22
- react_1.default.createElement(react_native_1.View, { style: styles.giftPackBar }, selected && [...gifts, ...customGifts].indexOf(selected) !== -1 ? (react_1.default.createElement(react_native_1.View, { style: styles.sendWrapper },
23
- react_1.default.createElement(react_native_1.Text, { style: styles.sendText }, "\u015Eimdi g\u00F6ndermek istedi\u011Fin ki\u015Fiyi se\u00E7"))) : (react_1.default.createElement(react_1.default.Fragment, null,
24
- react_1.default.createElement(react_native_1.View, { style: styles.giftPackTitleWrapper },
25
- react_1.default.createElement(react_native_1.Text, { style: styles.giftPackTitle },
26
- remain == 0 && "🔒 ",
27
- title || pack.name),
28
- !!remain && remain > 0 && (react_1.default.createElement(react_native_1.Text, { style: styles.giftPackTitle },
29
- "Kalan Kullan\u0131m: ",
30
- remain))),
31
- (pack.priceType !== "ad" || loaded) && (react_1.default.createElement(Buttons_1.GiftBuyButton, { onPress: () => onBuyPress(pack) }, buttonText || pack.buttonText))))),
32
- react_1.default.createElement(react_native_1.View, { style: [styles.buttonIcons] },
33
- !!customGifts.length && (react_1.default.createElement(react_native_1.View, { style: [styles.buttonIcons, { marginBottom: 0 }] }, customGifts.map((item, key) => {
34
- let giftElement = react_1.default.createElement(react_native_1.Text, null, item);
35
- if (item.indexOf("a") === 0) {
36
- giftElement = (react_1.default.createElement(react_native_1.Image, { style: [
37
- { width: 16, height: 16 },
38
- { opacity: remain == 0 ? 0.7 : 1 },
39
- ], accessibilityLabel: item, source: Utils_1.Assets.getSource("gift", item, "icon") }));
40
- }
41
- return (react_1.default.createElement(Views_1.TouchableView, { out: true, key: key, onPress: () => onSelect(item, pack.id), style: [
42
- styles.button,
43
- selected === item ? styles.buttonSelected : {},
44
- ] }, giftElement));
45
- }))),
46
- gifts.map((item, key) => {
47
- let giftElement = react_1.default.createElement(react_native_1.Text, null, item);
48
- if (item.indexOf("a") === 0) {
49
- giftElement = (react_1.default.createElement(react_native_1.Image, { style: [
50
- { width: 16, height: 16 },
51
- { opacity: remain == 0 ? 0.7 : 1 },
52
- ], accessibilityLabel: item.toString(), source: Utils_1.Assets.getSource("gift", item, "icon") }));
53
- }
54
- return (react_1.default.createElement(Views_1.TouchableView, { out: true, key: key, onPress: () => onSelect(item, pack.id), style: [
55
- styles.button,
56
- selected === item ? styles.buttonSelected : {},
57
- ] }, giftElement));
58
- }))));
31
+ const isSelected = selected && [...gifts, ...customGifts].indexOf(selected) !== -1;
32
+ return react_1.default.useMemo(() => {
33
+ return (react_1.default.createElement(react_native_1.View, { style: styles.wrapper },
34
+ react_1.default.createElement(react_native_1.View, { style: styles.giftPackBar }, isSelected ? (react_1.default.createElement(react_native_1.View, { style: styles.sendWrapper },
35
+ react_1.default.createElement(react_native_1.Text, { style: styles.sendText }, "\u015Eimdi g\u00F6ndermek istedi\u011Fin ki\u015Fiyi se\u00E7"))) : (react_1.default.createElement(react_1.default.Fragment, null,
36
+ react_1.default.createElement(react_native_1.View, { style: styles.giftPackTitleWrapper },
37
+ react_1.default.createElement(react_native_1.Text, { style: styles.giftPackTitle },
38
+ remain == 0 && "🔒 ",
39
+ title || pack.name),
40
+ !!remain && remain > 0 && (react_1.default.createElement(react_native_1.Text, { style: styles.giftPackTitle },
41
+ "Kalan Kullan\u0131m: ",
42
+ remain))),
43
+ (pack.priceType !== "ad" || loaded) && (react_1.default.createElement(Buttons_1.GiftBuyButton, { onPress: () => onBuyPress(pack) }, buttonText || pack.buttonText))))),
44
+ react_1.default.createElement(react_native_1.View, { style: [styles.buttonIcons] },
45
+ !!customGifts.length && (react_1.default.createElement(react_native_1.View, { style: [styles.buttonIcons, { marginBottom: 0 }] }, customGifts.map((item, key) => {
46
+ return (react_1.default.createElement(exports.GiftPackItem, { key: key, item: item, onSelect: onSelect, pack: pack, isEmpty: remain === 0, isSelected: selected == item }));
47
+ }))),
48
+ gifts.map((item, key) => {
49
+ return (react_1.default.createElement(exports.GiftPackItem, { key: key, item: item, onSelect: onSelect, pack: pack, isEmpty: remain === 0, isSelected: selected === item }));
50
+ }))));
51
+ }, [selected, remain, title, pack]);
59
52
  };
60
53
  exports.GiftPackBar = GiftPackBar;
61
54
  const { height } = react_native_1.Dimensions.get("window");
@@ -100,7 +93,7 @@ const styles = react_native_1.StyleSheet.create({
100
93
  margin: 1,
101
94
  borderRadius: 4,
102
95
  borderWidth: 1,
103
- borderColor: "#66aadd",
96
+ borderColor: "transparent",
104
97
  },
105
98
  buttonSelected: {
106
99
  backgroundColor: "#ffffff",
@@ -3,13 +3,17 @@ import React from "react";
3
3
  declare type Props = {
4
4
  gold: number;
5
5
  diamond: number;
6
+ ticket: number;
6
7
  gifts: number;
8
+ style: any;
7
9
  goldIcon: ImageSourcePropType;
8
10
  diamondIcon: ImageSourcePropType;
11
+ ticketIcon: ImageSourcePropType;
9
12
  giftIcon: ImageSourcePropType;
10
13
  titleText?: string;
11
14
  myGoldsText?: string;
12
15
  myDiamondsText?: string;
16
+ myTicketsText?: string;
13
17
  myGiftsText?: string;
14
18
  };
15
19
  export declare const MarketInfo: React.FC<Props & ViewProps>;
@@ -1 +1 @@
1
- {"version":3,"file":"MarketInfo.d.ts","sourceRoot":"","sources":["../../src/Markets/MarketInfo.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAS,mBAAmB,EAAoB,SAAS,EAAE,MAAM,cAAc,CAAC;AACvF,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,aAAK,KAAK,GAAG;IACX,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,mBAAmB,CAAC;IAC9B,WAAW,EAAE,mBAAmB,CAAC;IACjC,QAAQ,EAAE,mBAAmB,CAAC;IAC9B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,WAAW,CAAC,EAAE,MAAM,CAAC;CAEtB,CAAA;AACD,eAAO,MAAM,UAAU,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,GAAG,SAAS,CA4BlD,CAAC"}
1
+ {"version":3,"file":"MarketInfo.d.ts","sourceRoot":"","sources":["../../src/Markets/MarketInfo.tsx"],"names":[],"mappings":"AAAA,OAAO,EAEL,mBAAmB,EAGnB,SAAS,EACV,MAAM,cAAc,CAAC;AACtB,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,aAAK,KAAK,GAAG;IACX,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,GAAG,CAAC;IACX,QAAQ,EAAE,mBAAmB,CAAC;IAC9B,WAAW,EAAE,mBAAmB,CAAC;IACjC,UAAU,EAAE,mBAAmB,CAAC;IAChC,QAAQ,EAAE,mBAAmB,CAAC;IAC9B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,CAAC;AACF,eAAO,MAAM,UAAU,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,GAAG,SAAS,CA8ClD,CAAC"}
@@ -7,9 +7,9 @@ exports.MarketInfo = void 0;
7
7
  const react_native_1 = require("react-native");
8
8
  const react_1 = __importDefault(require("react"));
9
9
  const Typography_1 = require("../Typography");
10
- const MarketInfo = ({ gold, diamond, gifts, goldIcon, diamondIcon, giftIcon, titleText = "Hesabım", myGoldsText = "Altınlarım:", myDiamondsText = "Elmaslarım:", myGiftsText = "Hediyelerim:" }) => {
11
- return react_1.default.createElement(react_native_1.View, { style: styles.info },
12
- react_1.default.createElement(Typography_1.Typography, { bold: true, style: styles.title }, titleText),
10
+ const MarketInfo = ({ gold, diamond, gifts, style, ticket, goldIcon, diamondIcon, ticketIcon, giftIcon, titleText, myGoldsText = "Altınlarım:", myDiamondsText = "Elmaslarım:", myTicketsText = "Elmaslarım:", myGiftsText = "Hediyelerim:", }) => {
11
+ return (react_1.default.createElement(react_native_1.View, { style: [styles.info, style] },
12
+ !!titleText && (react_1.default.createElement(Typography_1.Typography, { bold: true, style: styles.title }, titleText)),
13
13
  react_1.default.createElement(react_native_1.View, { style: styles.line },
14
14
  react_1.default.createElement(Typography_1.Typography, { style: styles.label }, myGoldsText),
15
15
  react_1.default.createElement(Typography_1.Typography, { bold: true }, gold),
@@ -18,37 +18,41 @@ const MarketInfo = ({ gold, diamond, gifts, goldIcon, diamondIcon, giftIcon, tit
18
18
  react_1.default.createElement(Typography_1.Typography, { style: styles.label }, myDiamondsText),
19
19
  react_1.default.createElement(Typography_1.Typography, { bold: true }, diamond),
20
20
  react_1.default.createElement(react_native_1.Image, { style: styles.image, source: diamondIcon })),
21
+ react_1.default.createElement(react_native_1.View, { style: styles.line },
22
+ react_1.default.createElement(Typography_1.Typography, { style: styles.label }, myTicketsText),
23
+ react_1.default.createElement(Typography_1.Typography, { bold: true }, ticket),
24
+ react_1.default.createElement(react_native_1.Image, { style: styles.image, source: ticketIcon })),
21
25
  react_1.default.createElement(react_native_1.View, { style: styles.line },
22
26
  react_1.default.createElement(Typography_1.Typography, { style: styles.label }, myGiftsText),
23
27
  react_1.default.createElement(Typography_1.Typography, { bold: true }, gifts),
24
- react_1.default.createElement(react_native_1.Image, { style: styles.image, source: giftIcon })));
28
+ react_1.default.createElement(react_native_1.Image, { style: styles.image, source: giftIcon }))));
25
29
  };
26
30
  exports.MarketInfo = MarketInfo;
27
31
  const styles = react_native_1.StyleSheet.create({
28
32
  info: {
29
33
  flex: 1,
30
- padding: 20
34
+ padding: 20,
31
35
  },
32
36
  line: {
33
- paddingVertical: 4,
34
- paddingHorizontal: 10,
35
- borderRadius: 8,
36
- backgroundColor: "#00000020",
37
+ paddingVertical: 0,
38
+ borderBottomColor: "#e0e0e022",
39
+ borderBottomWidth: 1,
40
+ paddingHorizontal: 0,
37
41
  flexDirection: "row",
38
42
  alignItems: "center",
39
- marginBottom: 10
43
+ marginBottom: 10,
40
44
  },
41
45
  label: {
42
- marginRight: "auto"
46
+ marginRight: "auto",
43
47
  },
44
48
  title: {
45
49
  textAlign: "center",
46
- marginBottom: 20
50
+ marginBottom: 20,
47
51
  },
48
52
  image: {
49
53
  width: 30,
50
54
  height: 30,
51
55
  marginLeft: 10,
52
- resizeMode: "contain"
53
- }
56
+ resizeMode: "contain",
57
+ },
54
58
  });
@@ -12,6 +12,7 @@ declare type Props = {
12
12
  color?: string;
13
13
  badge?: string;
14
14
  feature?: boolean;
15
+ disabled?: boolean;
15
16
  value?: ItemValueType;
16
17
  options?: Array<OptionItem>;
17
18
  onPress?: (event?: GestureResponderEvent) => void;
@@ -1 +1 @@
1
- {"version":3,"file":"MenuOptions.d.ts","sourceRoot":"","sources":["../../src/Menus/MenuOptions.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAC;AACxC,OAAO,EAAE,qBAAqB,EAAE,SAAS,EAA0B,MAAM,cAAc,CAAC;AAMxF,aAAK,aAAa,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,IAAI,CAAC;AAGtD,aAAK,UAAU,GAAG;IAChB,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,aAAa,CAAA;CACrB,CAAA;AAGD,aAAK,KAAK,GAAG;IACX,KAAK,CAAC,EAAE,SAAS,CAAC,GAAG,CAAC,CAAC;IACvB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,KAAK,CAAC,EAAE,aAAa,CAAC;IACtB,OAAO,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC,CAAC;IAC5B,OAAO,CAAC,EAAE,CAAC,KAAK,CAAC,EAAE,qBAAqB,KAAK,IAAI,CAAC;IAClD,QAAQ,CAAC,EAAE,CAAC,KAAK,CAAC,EAAE,aAAa,KAAK,IAAI,CAAC;CAC5C,CAAC;AAEF,eAAO,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,CAkDvC,CAAC"}
1
+ {"version":3,"file":"MenuOptions.d.ts","sourceRoot":"","sources":["../../src/Menus/MenuOptions.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAC;AACxC,OAAO,EACL,qBAAqB,EACrB,SAAS,EAIV,MAAM,cAAc,CAAC;AAMtB,aAAK,aAAa,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,IAAI,CAAC;AAEtD,aAAK,UAAU,GAAG;IAChB,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,aAAa,CAAC;CACtB,CAAC;AAEF,aAAK,KAAK,GAAG;IACX,KAAK,CAAC,EAAE,SAAS,CAAC,GAAG,CAAC,CAAC;IACvB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,KAAK,CAAC,EAAE,aAAa,CAAC;IACtB,OAAO,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC,CAAC;IAC5B,OAAO,CAAC,EAAE,CAAC,KAAK,CAAC,EAAE,qBAAqB,KAAK,IAAI,CAAC;IAClD,QAAQ,CAAC,EAAE,CAAC,KAAK,CAAC,EAAE,aAAa,KAAK,IAAI,CAAC;CAC5C,CAAC;AAEF,eAAO,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,CAmFvC,CAAC"}
@@ -10,24 +10,34 @@ const Views_1 = require("../Views");
10
10
  const Typography_1 = require("../Typography");
11
11
  const Utils_1 = require("../Utils");
12
12
  const Themes_1 = require("../Themes");
13
- const MenuOptions = ({ children, style, color, onPress, feature, iconName, iconFont = "MaterialIcons", badge, value, options, onChange, }) => {
13
+ const MenuOptions = ({ children, style, color, onPress, feature, iconName, disabled, iconFont = "MaterialIcons", badge, value, options, onChange, }) => {
14
14
  const { baseTextColor } = Themes_1.useColors();
15
15
  const textColor = color ? color : baseTextColor;
16
16
  const setValue = (value) => {
17
+ if (disabled) {
18
+ return;
19
+ }
17
20
  onChange && onChange(value);
18
21
  };
19
- return (react_1.default.createElement(react_native_1.View, { style: [styles.wrapper, styles.container, feature && styles.border, style] },
22
+ return (react_1.default.createElement(react_native_1.View, { style: [
23
+ styles.wrapper,
24
+ styles.container,
25
+ feature && styles.border,
26
+ disabled && { opacity: 0.5 },
27
+ style,
28
+ ] },
20
29
  react_1.default.createElement(Typography_1.Typography, { size: 14, color: textColor, bold: feature, style: [feature && { textDecorationLine: "underline" }] }, children),
21
- !!badge && react_1.default.createElement(react_native_1.View, { style: styles.badge },
22
- react_1.default.createElement(react_native_1.Text, { style: styles.badgeText }, badge)),
30
+ !!badge && (react_1.default.createElement(react_native_1.View, { style: styles.badge },
31
+ react_1.default.createElement(react_native_1.Text, { style: styles.badgeText }, badge))),
23
32
  react_1.default.createElement(react_native_1.View, { style: styles.flex }),
24
33
  !!iconName && (react_1.default.createElement(react_native_1.View, { accessibilityElementsHidden: true },
25
34
  react_1.default.createElement(Utils_1.Icon, { name: iconName, color: textColor, font: iconFont, style: styles.icon, size: 18 }))),
26
- react_1.default.createElement(react_native_1.View, { style: styles.values }, !!options && options.map((item, key) => {
27
- const isActive = item.value === value;
28
- return react_1.default.createElement(Views_1.TouchableView, { onPress: () => setValue(item.value), style: [styles.value, isActive && styles.valueActive], accessibilityState: { selected: isActive }, wrapperStyle: styles.valueWrapper, key: key },
29
- react_1.default.createElement(react_native_1.Text, { style: [styles.valueText, isActive && styles.valueTextActive] }, item.label));
30
- }))));
35
+ react_1.default.createElement(react_native_1.View, { style: styles.values }, !!options &&
36
+ options.map((item, key) => {
37
+ const isActive = item.value === value;
38
+ return (react_1.default.createElement(Views_1.TouchableView, { onPress: () => setValue(item.value), disabled: disabled, style: [styles.value, isActive && styles.valueActive], accessibilityState: { selected: isActive }, wrapperStyle: styles.valueWrapper, key: key },
39
+ react_1.default.createElement(react_native_1.Text, { style: [styles.valueText, isActive && styles.valueTextActive] }, item.label)));
40
+ }))));
31
41
  };
32
42
  exports.MenuOptions = MenuOptions;
33
43
  const styles = react_native_1.StyleSheet.create({
@@ -38,7 +48,7 @@ const styles = react_native_1.StyleSheet.create({
38
48
  container: {
39
49
  flexDirection: "row",
40
50
  alignItems: "center",
41
- flexWrap: "wrap"
51
+ flexWrap: "wrap",
42
52
  },
43
53
  border: {
44
54
  flex: 1,
@@ -48,10 +58,10 @@ const styles = react_native_1.StyleSheet.create({
48
58
  paddingVertical: 10,
49
59
  marginHorizontal: 10,
50
60
  borderRadius: 8,
51
- paddingHorizontal: 10
61
+ paddingHorizontal: 10,
52
62
  },
53
63
  icon: {
54
- marginRight: 0
64
+ marginRight: 0,
55
65
  },
56
66
  flex: {
57
67
  flex: 1,
@@ -64,13 +74,13 @@ const styles = react_native_1.StyleSheet.create({
64
74
  justifyContent: "center",
65
75
  width: 16,
66
76
  height: 16,
67
- borderRadius: 16
77
+ borderRadius: 16,
68
78
  },
69
79
  badgeText: {
70
80
  color: "#ffffff",
71
81
  fontSize: 11,
72
82
  paddingLeft: 1,
73
- fontWeight: "bold"
83
+ fontWeight: "bold",
74
84
  },
75
85
  values: {
76
86
  marginLeft: -3,
@@ -81,7 +91,7 @@ const styles = react_native_1.StyleSheet.create({
81
91
  valueWrapper: {
82
92
  flex: 1,
83
93
  alignItems: "stretch",
84
- justifyContent: "center"
94
+ justifyContent: "center",
85
95
  },
86
96
  value: {
87
97
  backgroundColor: "transparent",
@@ -100,14 +110,14 @@ const styles = react_native_1.StyleSheet.create({
100
110
  fontSize: 11,
101
111
  paddingLeft: 1,
102
112
  fontWeight: "bold",
103
- textAlign: "center"
113
+ textAlign: "center",
104
114
  },
105
115
  valueActive: {
106
116
  backgroundColor: "#00B3FF",
107
117
  borderColor: "#00B3FF",
108
- borderWidth: 1
118
+ borderWidth: 1,
109
119
  },
110
120
  valueTextActive: {
111
121
  color: "#ffffff",
112
- }
122
+ },
113
123
  });
@@ -3,10 +3,12 @@ import { ImageSourcePropType, StyleProp } from "react-native";
3
3
  declare type Props = {
4
4
  style?: StyleProp<any>;
5
5
  avatarStyle?: StyleProp<any>;
6
+ icon?: string;
6
7
  userName: string;
7
8
  avatar: ImageSourcePropType;
8
9
  color?: string;
9
10
  isOnline?: boolean;
11
+ onNamePress?: () => void;
10
12
  };
11
13
  export declare const MenuUserItemComponent: React.FC<Props>;
12
14
  export declare const MenuUserItem: React.FC<Props>;
@@ -1 +1 @@
1
- {"version":3,"file":"MenuUserItem.d.ts","sourceRoot":"","sources":["../../src/Menus/MenuUserItem.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,mBAAmB,EAAE,SAAS,EAAoB,MAAM,cAAc,CAAC;AAKhF,aAAK,KAAK,GAAG;IACX,KAAK,CAAC,EAAE,SAAS,CAAC,GAAG,CAAC,CAAC;IACvB,WAAW,CAAC,EAAE,SAAS,CAAC,GAAG,CAAC,CAAC;IAC7B,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,mBAAmB,CAAC;IAC5B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,CAAC;AAEF,eAAO,MAAM,qBAAqB,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,CA4BjD,CAAC;AAgCF,eAAO,MAAM,YAAY,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,CAAqC,CAAC"}
1
+ {"version":3,"file":"MenuUserItem.d.ts","sourceRoot":"","sources":["../../src/Menus/MenuUserItem.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EACL,mBAAmB,EACnB,SAAS,EAIV,MAAM,cAAc,CAAC;AAKtB,aAAK,KAAK,GAAG;IACX,KAAK,CAAC,EAAE,SAAS,CAAC,GAAG,CAAC,CAAC;IACvB,WAAW,CAAC,EAAE,SAAS,CAAC,GAAG,CAAC,CAAC;IAC7B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,mBAAmB,CAAC;IAC5B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,IAAI,CAAC;CAC1B,CAAC;AAEF,eAAO,MAAM,qBAAqB,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,CAqDjD,CAAC;AAmCF,eAAO,MAAM,YAAY,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,CAAqC,CAAC"}
@@ -9,13 +9,18 @@ const react_native_1 = require("react-native");
9
9
  const Utils_1 = require("../Utils");
10
10
  const Typography_1 = require("../Typography");
11
11
  const Themes_1 = require("../Themes");
12
- const MenuUserItemComponent = ({ children, color, isOnline, avatar, style, avatarStyle, userName, }) => {
12
+ const MenuUserItemComponent = ({ children, color, isOnline, avatar, icon, style, onNamePress, avatarStyle, userName, }) => {
13
13
  const { baseTextColor } = Themes_1.useColors();
14
14
  const textColor = color ? color : baseTextColor;
15
+ const _renerContent = () => {
16
+ return (react_1.default.createElement(react_1.default.Fragment, null,
17
+ !!icon && (react_1.default.createElement(Typography_1.Typography, { size: 14, style: styles.icon }, icon)),
18
+ !!avatar && (react_1.default.createElement(Utils_1.FadeImage, { opacity: 0.1, source: avatar, style: [styles.avatar, avatarStyle] })),
19
+ !!isOnline && react_1.default.createElement(react_native_1.View, { style: styles.isOnline }),
20
+ react_1.default.createElement(Typography_1.Typography, { size: 14, color: textColor, style: styles.name }, userName)));
21
+ };
15
22
  return (react_1.default.createElement(react_native_1.View, { style: [styles.wrapper, style] },
16
- !!avatar && (react_1.default.createElement(Utils_1.FadeImage, { opacity: 0.1, source: avatar, style: [styles.avatar, avatarStyle] })),
17
- !!isOnline && react_1.default.createElement(react_native_1.View, { style: styles.isOnline }),
18
- react_1.default.createElement(Typography_1.Typography, { size: 14, color: textColor, style: styles.name }, userName),
23
+ !!onNamePress ? (react_1.default.createElement(react_native_1.TouchableOpacity, { onPress: onNamePress, style: { flex: 1, flexDirection: "row" } }, _renerContent())) : (_renerContent()),
19
24
  children));
20
25
  };
21
26
  exports.MenuUserItemComponent = MenuUserItemComponent;
@@ -34,6 +39,9 @@ const styles = react_native_1.StyleSheet.create({
34
39
  marginRight: 8,
35
40
  borderRadius: 5,
36
41
  },
42
+ icon: {
43
+ marginRight: 10,
44
+ },
37
45
  name: {
38
46
  flex: 1,
39
47
  },
@@ -8,7 +8,6 @@ declare type Props = {
8
8
  faded?: boolean;
9
9
  deadFocus?: boolean;
10
10
  vampiresFocus?: boolean;
11
- myName?: string;
12
11
  appearance?: "dark" | "light";
13
12
  messages: Array<MessageItem>;
14
13
  labelFormatter: (user: string) => {
@@ -1 +1 @@
1
- {"version":3,"file":"MessageList.d.ts","sourceRoot":"","sources":["../../src/Messages/MessageList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAML,SAAS,EACV,MAAM,cAAc,CAAC;AAItB,aAAK,WAAW,GAAG;IACjB,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;CACpB,CAAC;AAEF,aAAK,KAAK,GAAG;IACX,KAAK,CAAC,EAAE,SAAS,CAAC,GAAG,CAAC,CAAC;IACvB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,UAAU,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC;IAC9B,QAAQ,EAAE,KAAK,CAAC,WAAW,CAAC,CAAC;IAC7B,cAAc,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK;QAAE,WAAW,EAAE,MAAM,CAAC;QAAC,UAAU,EAAE,GAAG,CAAA;KAAE,CAAC;CAC5E,CAAC;AAEF,eAAO,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,CAqIvC,CAAC"}
1
+ {"version":3,"file":"MessageList.d.ts","sourceRoot":"","sources":["../../src/Messages/MessageList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAML,SAAS,EACV,MAAM,cAAc,CAAC;AAItB,aAAK,WAAW,GAAG;IACjB,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAC;CACpB,CAAC;AAEF,aAAK,KAAK,GAAG;IACX,KAAK,CAAC,EAAE,SAAS,CAAC,GAAG,CAAC,CAAC;IACvB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,UAAU,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC;IAC9B,QAAQ,EAAE,KAAK,CAAC,WAAW,CAAC,CAAC;IAC7B,cAAc,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK;QAAE,WAAW,EAAE,MAAM,CAAC;QAAC,UAAU,EAAE,GAAG,CAAA;KAAE,CAAC;CAC5E,CAAC;AAEF,eAAO,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC,KAAK,CAmGvC,CAAC"}