<script type="module">
, в нем будет объект guisvar guis = {
// ....
IcosahedronGeometry: function ( mesh ) {
var data = {
radius: 10,
detail: 0
};
function generateGeometry() {
updateGroupGeometry( mesh,
new IcosahedronGeometry(
data.radius, data.detail
)
);
}
var folder = gui.addFolder( 'THREE.IcosahedronGeometry' );
folder.add( data, 'radius', 1, 20 ).onChange( generateGeometry );
folder.add( data, 'detail', 0, 5 ).step( 1 ).onChange( generateGeometry );
generateGeometry();
},
// ....
}
наложить с помощью clip path и псевдоэлемента?
// Output Avatar 1
ctx.save(); // <- сохраняем контекст
ctx.beginPath();
ctx.arc(125, 125, 100, 0, Math.PI * 2, true);
ctx.closePath();
ctx.clip();
const avatar1 = await loadImage(member.user.displayAvatarURL({ format: 'jpg' }));
ctx.drawImage(avatar1, 25, 25, 200, 200);
ctx.restore(); // <- восстанавливаем контекст
nth-child
, а навешать классы нужным элементам. let submit = $("[data-submit]");
submit.on("click", function () {
let roomSearch = parseInt($("#rooms").val());
let floor = parseInt($("#floors").val());
$("[data-room][data-floor]").each(function () {
let roomHave = $(this).data("room");
let floorsHave = $(this).data("floor");
if (roomHave !== roomSearch && floorsHave !== floor) {
$(this).addClass("hide");
} else $(this).removeClass("hide");
});
});
Car.prototype.moveRight = function (dx) {
this.x += 5;
if (this.x < dx) {
setTimeout(() => this.moveRight(dx), 16);
} else {
this.x = dx;
}
this.carElement.css({
left: this.x,
top: this.y
});
};
var nissan = new Car(100, 200);
nissan.moveRight(500);
text-align-last: justify;