100 lines
		
	
	
		
			1.6 KiB
		
	
	
	
		
			Vue
		
	
	
	
	
	
			
		
		
	
	
			100 lines
		
	
	
		
			1.6 KiB
		
	
	
	
		
			Vue
		
	
	
	
	
	
<!--
 | 
						|
 * @Author: zhp
 | 
						|
 * @Date: 2024-06-06 14:22:56
 | 
						|
 * @LastEditTime: 2024-06-07 10:53:39
 | 
						|
 * @LastEditors: zhp
 | 
						|
 * @Description:
 | 
						|
-->
 | 
						|
 | 
						|
<template>
 | 
						|
  <button
 | 
						|
    class="copilot-btn"
 | 
						|
    :class="[active ? 'active' : '']"
 | 
						|
    @click="$emit('click', label)"
 | 
						|
  >
 | 
						|
    {{ label }}
 | 
						|
  </button>
 | 
						|
</template>
 | 
						|
 | 
						|
<script>
 | 
						|
export default {
 | 
						|
  name: "CopilotButton",
 | 
						|
  props: {
 | 
						|
    label: {
 | 
						|
      type: String,
 | 
						|
      required: true,
 | 
						|
    },
 | 
						|
    active: {
 | 
						|
      type: Boolean,
 | 
						|
      default: false,
 | 
						|
    },
 | 
						|
  },
 | 
						|
 | 
						|
};
 | 
						|
</script>
 | 
						|
 | 
						|
<style>
 | 
						|
 | 
						|
button {
 | 
						|
  appearance: none;
 | 
						|
  outline: none;
 | 
						|
  border: none;
 | 
						|
  background: none;
 | 
						|
}
 | 
						|
</style>
 | 
						|
 | 
						|
<style scoped>
 | 
						|
.copilot-btn {
 | 
						|
  /* flex: 1; */
 | 
						|
  /* position: relative; */
 | 
						|
  width: 88px;
 | 
						|
  height: 32px;
 | 
						|
  background: #01306C;
 | 
						|
  /* border-radius: 4px 0px 0px 4px; */
 | 
						|
  backdrop-filter: blur(3px);
 | 
						|
  /* text-align: center;
 | 
						|
  padding: 12px;
 | 
						|
  padding-left: 20px;
 | 
						|
  color: #fff;
 | 
						|
  font-size: 18px; */
 | 
						|
  font-family: PingFangSC, PingFang SC;
 | 
						|
  font-weight: 400;
 | 
						|
  font-size: 16px;
 | 
						|
  color: #FFFFFF;
 | 
						|
  line-height: 22px;
 | 
						|
  letter-spacing: 5px;
 | 
						|
  text-align: center;
 | 
						|
  font-style: normal;
 | 
						|
  letter-spacing: 10px;
 | 
						|
  cursor: pointer;
 | 
						|
}
 | 
						|
 | 
						|
.copilot-btn.active {
 | 
						|
  background: #1D74D8;
 | 
						|
  /* border-radius: 4px;; */
 | 
						|
}
 | 
						|
/* .copilot-btn::before,
 | 
						|
.copilot-btn::after {
 | 
						|
  content: "";
 | 
						|
  position: absolute;
 | 
						|
  width: 16px;
 | 
						|
  height: 16px;
 | 
						|
  top: 0;
 | 
						|
  background: transparent;
 | 
						|
  border-style: solid;
 | 
						|
  border-width: 2px;
 | 
						|
  border-color: transparent;
 | 
						|
  border-top-color: #007be4;
 | 
						|
}
 | 
						|
 | 
						|
.copilot-btn::before {
 | 
						|
  left: 0;
 | 
						|
  border-left-color: #007be4;
 | 
						|
}
 | 
						|
 | 
						|
.copilot-btn::after {
 | 
						|
  right: 0;
 | 
						|
  border-right-color: #007be4;
 | 
						|
} */
 | 
						|
</style>
 |