خاصية تغيير حجم النمط
مثال
جعل عنصر <div> يمكن تغيير حجمه:
document.getElementById("myDIV").style.resize = "both";
التعريف والاستخدام
تحدد خاصية تغيير الحجم ما إذا كان يمكن للمستخدم تغيير حجم العنصر أم لا.
ملاحظة: تنطبق خاصية تغيير الحجم على العناصر التي تكون قيمة تجاوز السعة المحسوبة لها شيئًا آخر غير "مرئية".
دعم المتصفح
Property | |||||
---|---|---|---|---|---|
resize | Yes | 79.0 | Yes | Yes | 15.0 |
بناء الجملة
إعادة خاصية تغيير الحجم:
object.style.resize
قم بتعيين خاصية تغيير الحجم:
object.style.resize = "none|both|horizontal|vertical|initial|inherit"
قيم الملكية
Value | Description |
---|---|
none | Default value. The user cannot resize the element |
both | The user can adjust both the height and the width of the element |
horizontal | The user can adjust the width of the element |
vertical | The user can adjust the height of the element |
initial | Sets this property to its default value. Read about initial |
inherit | Inherits this property from its parent element. Read about inherit |
تفاصيل تقنية
القيمة الافتراضية: | لا أحد |
---|---|
قيمة الإرجاع: | سلسلة ، تمثل خاصية تغيير الحجم لعنصر |
إصدار CSS | CSS3 |
الصفحات ذات الصلة
مرجع CSS: تغيير حجم الخاصية
❮ نمط الكائن