1 line
19 KiB
JSON
1 line
19 KiB
JSON
{"ast":null,"code":"import { computed } from \"vue\";\nimport { useStore } from \"vuex\";\nimport confirmBet from \"@/components/confirmBet.vue\";\nimport chipView from \"@/components/chipView.vue\";\nimport { nnData } from \"@/utils/common\";\nexport default {\n name: \"TableBullbull\",\n components: {\n confirmBet,\n chipView\n },\n props: {\n game_id: {\n type: [String, Number],\n default: 1\n },\n touch: {\n type: String,\n default: \"\"\n },\n bet_amount_msg: {\n type: Object,\n default: () => ({\n ...nnData.amount\n })\n },\n winArray: {\n type: Array,\n default: () => []\n },\n downChip: {\n type: Object,\n default: () => ({\n ...nnData.amount\n })\n },\n chipArray: {\n type: Object,\n default: () => ({\n ...nnData.array\n })\n }\n },\n setup(prop, context) {\n const store = useStore();\n const Type = computed(() => store.state.config.$Type);\n const Lang = computed(() => store.state.config.$lang);\n const downBet = (e, type) => {\n context.emit(\"downBet\", e, type);\n };\n const confirmChip = () => {\n context.emit(\"confirmChip\");\n };\n const cancelChip = () => {\n context.emit(\"cancelChip\");\n };\n return {\n Type,\n Lang,\n downBet,\n confirmChip,\n cancelChip\n };\n }\n};","map":{"version":3,"names":["computed","useStore","confirmBet","chipView","nnData","name","components","props","game_id","type","String","Number","default","touch","bet_amount_msg","Object","amount","winArray","Array","downChip","chipArray","array","setup","prop","context","store","Type","state","config","$Type","Lang","$lang","downBet","e","emit","confirmChip","cancelChip"],"sources":["/Users/li/Desktop/work/work2/OG/GamePortrait/src/components/PlayTable/TableBullbull.vue"],"sourcesContent":["<template>\n <div class=\"nn\">\n <div class=\"list\">\n <!-- 闲1 -->\n <span class=\"tab\">{{ Lang[Type].player }}1</span>\n <!-- 庄翻倍 -->\n <div class=\"item banker\">\n <confirmBet\n @confirm=\"confirmChip\"\n @cancel=\"cancelChip\"\n :data=\"{\n money: downChip.amount_player_1_banker_times,\n show: touch == 'amount_player_1_banker_times',\n times: true,\n game_id: game_id\n }\"\n ></confirmBet>\n <chipView\n @click=\"downBet($event, 'amount_player_1_banker_times')\"\n :list=\"chipArray.amount_player_1_banker_times\"\n :win=\"winArray.includes('player_1_banker')\"\n ></chipView>\n <div class=\"text\">\n <span class=\"big\">\n {{ Type != \"cn\" && Type != \"tw\" ? \"B\" : Lang[Type].banker }}\n </span>\n <span>{{ Lang[Type].double }}</span>\n </div>\n <div class=\"money\">\n {{ bet_amount_msg.amount_player_1_banker_times }}\n </div>\n </div>\n <!-- 庄平倍 -->\n <div class=\"item banker\">\n <confirmBet\n @confirm=\"confirmChip\"\n @cancel=\"cancelChip\"\n :data=\"{\n money: downChip.amount_player_1_banker,\n show: touch == 'amount_player_1_banker'\n }\"\n ></confirmBet>\n <chipView\n @click=\"downBet($event, 'amount_player_1_banker')\"\n :list=\"chipArray.amount_player_1_banker\"\n :win=\"winArray.includes('player_1_banker')\"\n ></chipView>\n <div class=\"text\">\n <span class=\"big\">\n {{ Type != \"cn\" && Type != \"tw\" ? \"B\" : Lang[Type].banker }}\n </span>\n <span>{{ Lang[Type].equal }}</span>\n </div>\n <div class=\"money\">{{ bet_amount_msg.amount_player_1_banker }}</div>\n </div>\n <!-- 闲翻倍 -->\n <div class=\"item palyer\">\n <confirmBet\n @confirm=\"confirmChip\"\n @cancel=\"cancelChip\"\n :data=\"{\n money: downChip.amount_player_1_times,\n show: touch == 'amount_player_1_times',\n times: true,\n game_id: game_id\n }\"\n ></confirmBet>\n <chipView\n @click=\"downBet($event, 'amount_player_1_times')\"\n :list=\"chipArray.amount_player_1_times\"\n :win=\"winArray.includes('player_1')\"\n ></chipView>\n <div class=\"text\">\n <span class=\"big\">\n {{ Type != \"cn\" && Type != \"tw\" ? \"P\" : Lang[Type].player }}\n </span>\n <span>{{ Lang[Type].double }}</span>\n </div>\n <div class=\"money\">{{ bet_amount_msg.amount_player_1_times }}</div>\n </div>\n <!-- 闲平倍 -->\n <div class=\"item palyer\">\n <confirmBet\n @confirm=\"confirmChip\"\n @cancel=\"cancelChip\"\n :data=\"{\n money: downChip.amount_player_1,\n show: touch == 'amount_player_1'\n }\"\n ></confirmBet>\n <chipView\n @click=\"downBet($event, 'amount_player_1')\"\n :list=\"chipArray.amount_player_1\"\n :win=\"winArray.includes('player_1')\"\n ></chipView>\n <div class=\"text\">\n <span class=\"big\">\n {{ Type != \"cn\" && Type != \"tw\" ? \"P\" : Lang[Type].player }}\n </span>\n <span>{{ Lang[Type].equal }}</span>\n </div>\n <div class=\"money\">{{ bet_amount_msg.amount_player_1 }}</div>\n </div>\n </div>\n <!-- 闲2 -->\n <div class=\"list\">\n <span class=\"tab\">{{ Lang[Type].player }}2</span>\n <!-- 庄翻倍 -->\n <div class=\"item banker\">\n <confirmBet\n @confirm=\"confirmChip\"\n @cancel=\"cancelChip\"\n :data=\"{\n money: downChip.amount_player_2_banker_times,\n show: touch == 'amount_player_2_banker_times',\n times: true,\n game_id: game_id\n }\"\n ></confirmBet>\n <chipView\n @click=\"downBet($event, 'amount_player_2_banker_times')\"\n :list=\"chipArray.amount_player_2_banker_times\"\n :win=\"winArray.includes('player_2_banker')\"\n ></chipView>\n <div class=\"text\">\n <span class=\"big\">\n {{ Type != \"cn\" && Type != \"tw\" ? \"B\" : Lang[Type].banker }}\n </span>\n <span>{{ Lang[Type].double }}</span>\n </div>\n <div class=\"money\">\n {{ bet_amount_msg.amount_player_2_banker_times }}\n </div>\n </div>\n <!-- 庄平倍 -->\n <div class=\"item banker\">\n <confirmBet\n @confirm=\"confirmChip\"\n @cancel=\"cancelChip\"\n :data=\"{\n money: downChip.amount_player_2_banker,\n show: touch == 'amount_player_2_banker'\n }\"\n ></confirmBet>\n <chipView\n @click=\"downBet($event, 'amount_player_2_banker')\"\n :list=\"chipArray.amount_player_2_banker\"\n :win=\"winArray.includes('player_2_banker')\"\n ></chipView>\n <div class=\"text\">\n <span class=\"big\">\n {{ Type != \"cn\" && Type != \"tw\" ? \"B\" : Lang[Type].banker }}\n </span>\n <span>{{ Lang[Type].equal }}</span>\n </div>\n <div class=\"money\">\n {{ bet_amount_msg.amount_player_2_banker }}\n </div>\n </div>\n <!-- 闲翻倍 -->\n <div class=\"item palyer\">\n <confirmBet\n @confirm=\"confirmChip\"\n @cancel=\"cancelChip\"\n :data=\"{\n money: downChip.amount_player_2_times,\n show: touch == 'amount_player_2_times',\n times: true,\n game_id: game_id\n }\"\n ></confirmBet>\n <chipView\n @click=\"downBet($event, 'amount_player_2_times')\"\n :list=\"chipArray.amount_player_2_times\"\n :win=\"winArray.includes('player_2')\"\n ></chipView>\n <div class=\"text\">\n <span class=\"big\">\n {{ Type != \"cn\" && Type != \"tw\" ? \"P\" : Lang[Type].player }}\n </span>\n <span>{{ Lang[Type].double }}</span>\n </div>\n <div class=\"money\">{{ bet_amount_msg.amount_player_2_times }}</div>\n </div>\n <!-- 闲平倍 -->\n <div class=\"item palyer\">\n <confirmBet\n @confirm=\"confirmChip\"\n @cancel=\"cancelChip\"\n :data=\"{\n money: downChip.amount_player_2,\n show: touch == 'amount_player_2'\n }\"\n ></confirmBet>\n <chipView\n @click=\"downBet($event, 'amount_player_2')\"\n :list=\"chipArray.amount_player_2\"\n :win=\"winArray.includes('player_2')\"\n ></chipView>\n <div class=\"text\">\n <span class=\"big\">\n {{ Type != \"cn\" && Type != \"tw\" ? \"P\" : Lang[Type].player }}\n </span>\n <span>{{ Lang[Type].equal }}</span>\n </div>\n <div class=\"money\">{{ bet_amount_msg.amount_player_2 }}</div>\n </div>\n </div>\n <!-- 闲3 -->\n <div class=\"list\">\n <span class=\"tab\">{{ Lang[Type].player }}3</span>\n <!-- 庄翻倍 -->\n <div class=\"item banker\">\n <confirmBet\n @confirm=\"confirmChip\"\n @cancel=\"cancelChip\"\n :data=\"{\n money: downChip.amount_player_3_banker_times,\n show: touch == 'amount_player_3_banker_times',\n times: true,\n game_id: game_id\n }\"\n ></confirmBet>\n <chipView\n @click=\"downBet($event, 'amount_player_3_banker_times')\"\n :list=\"chipArray.amount_player_3_banker_times\"\n :win=\"winArray.includes('player_3_banker')\"\n ></chipView>\n <div class=\"text\">\n <span class=\"big\">\n {{ Type != \"cn\" && Type != \"tw\" ? \"B\" : Lang[Type].banker }}\n </span>\n <span>{{ Lang[Type].double }}</span>\n </div>\n\n <div class=\"money\">\n {{ bet_amount_msg.amount_player_3_banker_times }}\n </div>\n </div>\n <!-- 庄平倍 -->\n <div class=\"item banker\">\n <confirmBet\n @confirm=\"confirmChip\"\n @cancel=\"cancelChip\"\n :data=\"{\n money: downChip.amount_player_3_banker,\n show: touch == 'amount_player_3_banker'\n }\"\n ></confirmBet>\n <chipView\n @click=\"downBet($event, 'amount_player_3_banker')\"\n :list=\"chipArray.amount_player_3_banker\"\n :win=\"winArray.includes('player_3_banker')\"\n ></chipView>\n <div class=\"text\">\n <span class=\"big\">\n {{ Type != \"cn\" && Type != \"tw\" ? \"B\" : Lang[Type].banker }}\n </span>\n <span>{{ Lang[Type].equal }}</span>\n </div>\n <div class=\"money\">{{ bet_amount_msg.amount_player_3_banker }}</div>\n </div>\n <!-- 闲翻倍 -->\n <div class=\"item palyer\">\n <confirmBet\n @confirm=\"confirmChip\"\n @cancel=\"cancelChip\"\n :data=\"{\n money: downChip.amount_player_3_times,\n show: touch == 'amount_player_3_times',\n times: true,\n game_id: game_id\n }\"\n ></confirmBet>\n <chipView\n @click=\"downBet($event, 'amount_player_3_times')\"\n :list=\"chipArray.amount_player_3_times\"\n :win=\"winArray.includes('player_3')\"\n ></chipView>\n <div class=\"text\">\n <span class=\"big\">\n {{ Type != \"cn\" && Type != \"tw\" ? \"P\" : Lang[Type].player }}\n </span>\n <span>{{ Lang[Type].double }}</span>\n </div>\n <div class=\"money\">{{ bet_amount_msg.amount_player_3_times }}</div>\n </div>\n <!-- 闲平倍 -->\n <div class=\"item palyer\">\n <confirmBet\n @confirm=\"confirmChip\"\n @cancel=\"cancelChip\"\n :data=\"{\n money: downChip.amount_player_3,\n show: touch == 'amount_player_3'\n }\"\n ></confirmBet>\n <chipView\n @click=\"downBet($event, 'amount_player_3')\"\n :list=\"chipArray.amount_player_3\"\n :win=\"winArray.includes('player_3')\"\n ></chipView>\n <div class=\"text\">\n <span class=\"big\">\n {{ Type != \"cn\" && Type != \"tw\" ? \"P\" : Lang[Type].player }}\n </span>\n <span>{{ Lang[Type].equal }}</span>\n </div>\n <div class=\"money\">{{ bet_amount_msg.amount_player_3 }}</div>\n </div>\n </div>\n </div>\n</template>\n\n<script>\nimport { computed } from \"vue\"\nimport { useStore } from \"vuex\"\nimport confirmBet from \"@/components/confirmBet.vue\"\nimport chipView from \"@/components/chipView.vue\"\nimport { nnData } from \"@/utils/common\"\nexport default {\n name: \"TableBullbull\",\n components: { confirmBet, chipView },\n props: {\n game_id: {\n type: [String, Number],\n default: 1\n },\n touch: {\n type: String,\n default: \"\"\n },\n bet_amount_msg: {\n type: Object,\n default: () => ({\n ...nnData.amount\n })\n },\n winArray: {\n type: Array,\n default: () => []\n },\n downChip: {\n type: Object,\n default: () => ({\n ...nnData.amount\n })\n },\n chipArray: {\n type: Object,\n default: () => ({ ...nnData.array })\n }\n },\n setup(prop, context) {\n const store = useStore()\n const Type = computed(() => store.state.config.$Type)\n const Lang = computed(() => store.state.config.$lang)\n const downBet = (e, type) => {\n context.emit(\"downBet\", e, type)\n }\n const confirmChip = () => {\n context.emit(\"confirmChip\")\n }\n const cancelChip = () => {\n context.emit(\"cancelChip\")\n }\n return { Type, Lang, downBet, confirmChip, cancelChip }\n }\n}\n</script>\n<style lang=\"scss\" scoped>\n/* 深色豪华主题配色 */\n$border-color: #444;\n$text-secondary: #888;\n$gold: #c5a059;\n\n.nn {\n display: flex;\n background: rgba(30, 30, 30, 0.95);\n .list {\n width: 33.33%;\n height: 100%;\n flex-wrap: wrap;\n border: none;\n position: relative;\n display: flex;\n box-sizing: border-box;\n &:first-child {\n .item:nth-of-type(1) {\n .chip-view {\n border-top-left-radius: 10px;\n }\n }\n .item:nth-of-type(3) {\n .chip-view {\n border-bottom-left-radius: 10px;\n }\n }\n }\n &:last-child {\n .item:nth-of-type(2) {\n border-right: none;\n .chip-view {\n border-top-right-radius: 10px;\n }\n }\n .item:nth-of-type(4) {\n border-right: none;\n .chip-view {\n border-bottom-right-radius: 10px;\n }\n }\n }\n .tab {\n position: absolute;\n top: -2px;\n color: #fff;\n font-size: 0.42rem;\n border: 1px solid $gold;\n padding: 1px 0.18rem;\n transform: scale(0.8) translateX(-50%);\n left: 50%;\n z-index: 2;\n background: rgba(30, 30, 30, 0.9);\n border-radius: 2px;\n font-weight: 500;\n }\n .item {\n position: relative;\n width: 50%;\n height: 50%;\n box-sizing: border-box;\n border-right: 1px solid $border-color;\n border-radius: 0;\n border-bottom: 1px solid $border-color;\n font-size: 0.45rem;\n &:nth-of-type(3),\n &:nth-of-type(4) {\n border-bottom: none;\n }\n &.unclick {\n &:after {\n content: \"\";\n position: absolute;\n width: 102%;\n border-bottom: 1px solid $border-color;\n top: 50%;\n transform: rotate(14deg);\n z-index: 6;\n left: -2px;\n }\n &.max:after {\n width: 104%;\n transform: rotate(21deg);\n }\n &.min:after {\n width: 104%;\n transform: rotate(21deg);\n }\n .chip-view {\n background: rgba(98, 74, 4, 0.4);\n }\n }\n\n .chip-box {\n position: absolute;\n width: 100%;\n height: 100%;\n left: 0;\n top: 0;\n &:active {\n background: rgba(255, 255, 255, 0.15);\n }\n }\n .text {\n position: relative;\n display: flex;\n justify-content: center;\n align-items: center;\n height: 100%;\n line-height: 1;\n z-index: 2;\n pointer-events: none;\n color: #fff;\n .big {\n font-weight: bold;\n padding-right: 0.24rem;\n padding-left: 0.2rem;\n }\n }\n .money {\n position: absolute;\n left: 0px;\n bottom: -2px;\n font-size: 0.24rem;\n font-weight: normal;\n transform: scale(0.7);\n color: $text-secondary;\n vertical-align: bottom;\n pointer-events: none;\n &::before {\n display: inline-block;\n content: \"总\";\n background: rgba(255, 255, 255, 0.2);\n font-size: 10px;\n border-radius: 0.615rem;\n width: 0.615rem;\n height: 0.615rem;\n text-align: center;\n line-height: 0.615rem;\n font-weight: normal;\n margin-right: 0.06rem;\n transform: scale(0.7);\n }\n }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