@@ -100,6 +107,7 @@ import { getFileAccessHttpUrl } from '/@/utils/common/compUtils';
const confirmLoading = ref
(false);
const showType = ref('0');
const ylurl = ref('');
+const rotationAngle = ref(0);
const zyInfo = ref({});
const globSetting = useGlobSetting();
const baseApiUrl = globSetting.domainUrl;
@@ -111,6 +119,7 @@ const videoOpen = ref(false);
const loop = ref(false);
const videoUrl = ref('');
+
//表单验证
const validatorRules = {
score: [{ required: true, message: '请输入分数!' }],
@@ -155,6 +164,13 @@ const videoUrl = ref('');
}
+function rotateImage() {
+ rotationAngle.value += 90; // 每次点击旋转90度
+}
+
+function rotateImage2() {
+ rotationAngle.value -= 90; // 每次点击旋转90度
+}
/**
* 新增
*/
@@ -367,4 +383,21 @@ video {
display: block;
max-width: 100%; /* 确保视频宽度不超过其容器宽度 */
}
+
+.image-container {
+ padding: 10px;
+ width:100%; /* 设置容器宽度 */
+ height: auto; /* 设置容器高度 */
+ overflow: hidden; /* 隐藏溢出的部分 */
+ display: flex;
+ align-items: center;
+ justify-content: center;
+}
+
+.rotated-image {
+ max-width: 100%; /* 最大宽度为容器宽度 */
+ max-height: 100%; /* 最大高度为容器高度 */
+ object-fit: contain; /* 保持图片内容不失真 */
+ transform: rotate(90deg); /* 假设图片已经旋转90度 */
+}